sdk 0.36.0 support and improve flow types

This commit is contained in:
Sean Yesmunt 2019-04-23 13:22:14 -04:00
parent af4410d0d7
commit 5f0fd9e9a5
97 changed files with 15152 additions and 3666 deletions

View file

@ -1,19 +1,7 @@
{ {
"plugins": ["flowtype"],
"extends": [
"airbnb-base",
"plugin:import/electron",
"plugin:flowtype/recommended",
"plugin:prettier/recommended"
],
"settings": {
"import/resolver": {
"webpack": {
"config": "webpack.config.js"
}
}
},
"parser": "babel-eslint", "parser": "babel-eslint",
"extends": ["standard", "standard-jsx", "plugin:flowtype/recommended"],
"plugins": ["flowtype", "import"],
"env": { "env": {
"browser": true, "browser": true,
"node": true "node": true
@ -22,9 +10,27 @@
"__": true "__": true
}, },
"rules": { "rules": {
"import/no-commonjs": "warn", "no-multi-spaces": 0,
"import/no-amd": "warn", "new-cap": 0,
"import/prefer-default-export": "ignore", "prefer-promise-reject-errors": 0,
"func-names": ["warn", "as-needed"] "no-unused-vars": 0,
"standard/object-curly-even-spacing": 0,
"handle-callback-err": 0,
"one-var": 0,
"object-curly-spacing": 0,
"no-redeclare": 0,
"no-return-await": 0,
"standard/no-callback-literal": 0,
"comma-dangle": ["error", "always-multiline"],
"space-before-function-paren": ["error", "never"],
"jsx-quotes": ["error", "prefer-double"],
"no-use-before-define": 0,
"semi": [
"error",
"always",
{
"omitLastInOneLineBlock": true
}
]
} }
} }

View file

@ -3,7 +3,12 @@
[include] [include]
[libs] [libs]
./flow-typed
[options] [options]
module.system.node.resolve_dirname=src module.system.node.resolve_dirname=./src
module.system.node.resolve_dirname=node_modules module.name_mapper='^redux\(.*\)$' -> '<PROJECT_ROOT>/src/redux\1'
module.name_mapper='^util\(.*\)$' -> '<PROJECT_ROOT>/src/util\1'
module.name_mapper='^constants\(.*\)$' -> '<PROJECT_ROOT>/src/constants\1'
module.name_mapper='^lbry\(.*\)$' -> '<PROJECT_ROOT>/src/lbry\1'
module.name_mapper='^lbryURI\(.*\)$' -> '<PROJECT_ROOT>/src/lbryURI\1'

View file

@ -1,12 +1,6 @@
{ {
"linters": { "linters": {
"src/**/*.{js,json}": [ "src/**/*.{js,json}": ["prettier --write", "git add"],
"prettier --write", "src/**/*.js": ["eslint --fix", "git add"]
"git add"
],
"src/**/*.js": [
"eslint --fix",
"git add"
]
} }
} }

552
dist/bundle.es.js vendored
View file

@ -78,8 +78,6 @@ const RESOLVE_URIS_STARTED = 'RESOLVE_URIS_STARTED';
const RESOLVE_URIS_COMPLETED = 'RESOLVE_URIS_COMPLETED'; const RESOLVE_URIS_COMPLETED = 'RESOLVE_URIS_COMPLETED';
const FETCH_CHANNEL_CLAIMS_STARTED = 'FETCH_CHANNEL_CLAIMS_STARTED'; const FETCH_CHANNEL_CLAIMS_STARTED = 'FETCH_CHANNEL_CLAIMS_STARTED';
const FETCH_CHANNEL_CLAIMS_COMPLETED = 'FETCH_CHANNEL_CLAIMS_COMPLETED'; const FETCH_CHANNEL_CLAIMS_COMPLETED = 'FETCH_CHANNEL_CLAIMS_COMPLETED';
const FETCH_CHANNEL_CLAIM_COUNT_STARTED = 'FETCH_CHANNEL_CLAIM_COUNT_STARTED';
const FETCH_CHANNEL_CLAIM_COUNT_COMPLETED = 'FETCH_CHANNEL_CLAIM_COUNT_COMPLETED';
const FETCH_CLAIM_LIST_MINE_STARTED = 'FETCH_CLAIM_LIST_MINE_STARTED'; const FETCH_CLAIM_LIST_MINE_STARTED = 'FETCH_CLAIM_LIST_MINE_STARTED';
const FETCH_CLAIM_LIST_MINE_COMPLETED = 'FETCH_CLAIM_LIST_MINE_COMPLETED'; const FETCH_CLAIM_LIST_MINE_COMPLETED = 'FETCH_CLAIM_LIST_MINE_COMPLETED';
const ABANDON_CLAIM_STARTED = 'ABANDON_CLAIM_STARTED'; const ABANDON_CLAIM_STARTED = 'ABANDON_CLAIM_STARTED';
@ -88,6 +86,7 @@ const FETCH_CHANNEL_LIST_STARTED = 'FETCH_CHANNEL_LIST_STARTED';
const FETCH_CHANNEL_LIST_COMPLETED = 'FETCH_CHANNEL_LIST_COMPLETED'; const FETCH_CHANNEL_LIST_COMPLETED = 'FETCH_CHANNEL_LIST_COMPLETED';
const CREATE_CHANNEL_STARTED = 'CREATE_CHANNEL_STARTED'; const CREATE_CHANNEL_STARTED = 'CREATE_CHANNEL_STARTED';
const CREATE_CHANNEL_COMPLETED = 'CREATE_CHANNEL_COMPLETED'; const CREATE_CHANNEL_COMPLETED = 'CREATE_CHANNEL_COMPLETED';
const CREATE_CHANNEL_FAILED = 'CREATE_CHANNEL_FAILED';
const PUBLISH_STARTED = 'PUBLISH_STARTED'; const PUBLISH_STARTED = 'PUBLISH_STARTED';
const PUBLISH_COMPLETED = 'PUBLISH_COMPLETED'; const PUBLISH_COMPLETED = 'PUBLISH_COMPLETED';
const PUBLISH_FAILED = 'PUBLISH_FAILED'; const PUBLISH_FAILED = 'PUBLISH_FAILED';
@ -289,8 +288,6 @@ var action_types = /*#__PURE__*/Object.freeze({
RESOLVE_URIS_COMPLETED: RESOLVE_URIS_COMPLETED, RESOLVE_URIS_COMPLETED: RESOLVE_URIS_COMPLETED,
FETCH_CHANNEL_CLAIMS_STARTED: FETCH_CHANNEL_CLAIMS_STARTED, FETCH_CHANNEL_CLAIMS_STARTED: FETCH_CHANNEL_CLAIMS_STARTED,
FETCH_CHANNEL_CLAIMS_COMPLETED: FETCH_CHANNEL_CLAIMS_COMPLETED, FETCH_CHANNEL_CLAIMS_COMPLETED: FETCH_CHANNEL_CLAIMS_COMPLETED,
FETCH_CHANNEL_CLAIM_COUNT_STARTED: FETCH_CHANNEL_CLAIM_COUNT_STARTED,
FETCH_CHANNEL_CLAIM_COUNT_COMPLETED: FETCH_CHANNEL_CLAIM_COUNT_COMPLETED,
FETCH_CLAIM_LIST_MINE_STARTED: FETCH_CLAIM_LIST_MINE_STARTED, FETCH_CLAIM_LIST_MINE_STARTED: FETCH_CLAIM_LIST_MINE_STARTED,
FETCH_CLAIM_LIST_MINE_COMPLETED: FETCH_CLAIM_LIST_MINE_COMPLETED, FETCH_CLAIM_LIST_MINE_COMPLETED: FETCH_CLAIM_LIST_MINE_COMPLETED,
ABANDON_CLAIM_STARTED: ABANDON_CLAIM_STARTED, ABANDON_CLAIM_STARTED: ABANDON_CLAIM_STARTED,
@ -299,6 +296,7 @@ var action_types = /*#__PURE__*/Object.freeze({
FETCH_CHANNEL_LIST_COMPLETED: FETCH_CHANNEL_LIST_COMPLETED, FETCH_CHANNEL_LIST_COMPLETED: FETCH_CHANNEL_LIST_COMPLETED,
CREATE_CHANNEL_STARTED: CREATE_CHANNEL_STARTED, CREATE_CHANNEL_STARTED: CREATE_CHANNEL_STARTED,
CREATE_CHANNEL_COMPLETED: CREATE_CHANNEL_COMPLETED, CREATE_CHANNEL_COMPLETED: CREATE_CHANNEL_COMPLETED,
CREATE_CHANNEL_FAILED: CREATE_CHANNEL_FAILED,
PUBLISH_STARTED: PUBLISH_STARTED, PUBLISH_STARTED: PUBLISH_STARTED,
PUBLISH_COMPLETED: PUBLISH_COMPLETED, PUBLISH_COMPLETED: PUBLISH_COMPLETED,
PUBLISH_FAILED: PUBLISH_FAILED, PUBLISH_FAILED: PUBLISH_FAILED,
@ -571,11 +569,115 @@ const SEARCH_OPTIONS = {
// //
const CHECK_DAEMON_STARTED_TRY_NUMBER = 200; const CHECK_DAEMON_STARTED_TRY_NUMBER = 200;
//
// Basic LBRY sdk connection config
// Offers a proxy to call LBRY sdk methods
//
const Lbry = { const Lbry = {
isConnected: false, isConnected: false,
connectPromise: null,
daemonConnectionString: 'http://localhost:5279', daemonConnectionString: 'http://localhost:5279',
pendingPublishTimeout: 20 * 60 * 1000
// Allow overriding daemon connection string (e.g. to `/api/proxy` for lbryweb)
setDaemonConnectionString: value => {
Lbry.daemonConnectionString = value;
},
// Allow overriding Lbry methods
overrides: {},
setOverride: (methodName, newMethod) => {
Lbry.overrides[methodName] = newMethod;
},
// Returns a human readable media type based on the content type or extension of a file that is returned by the sdk
getMediaType: (contentType, extname) => {
if (extname) {
const formats = [[/^(mp4|m4v|webm|flv|f4v|ogv)$/i, 'video'], [/^(mp3|m4a|aac|wav|flac|ogg|opus)$/i, 'audio'], [/^(html|htm|xml|pdf|odf|doc|docx|md|markdown|txt|epub|org)$/i, 'document'], [/^(stl|obj|fbx|gcode)$/i, '3D-file']];
const res = formats.reduce((ret, testpair) => {
switch (testpair[0].test(ret)) {
case true:
return testpair[1];
default:
return ret;
}
}, extname);
return res === extname ? 'unknown' : res;
} else if (contentType) {
// $FlowFixMe
return (/^[^/]+/.exec(contentType)[0]
);
}
return 'unknown';
},
//
// Lbry SDK Methods
// https://lbry.tech/api/sdk
//
status: (params = {}) => daemonCallWithResult('status', params),
stop: () => daemonCallWithResult('stop', {}),
version: () => daemonCallWithResult('version', {}),
// Claim fetching and manipulation
resolve: params => daemonCallWithResult('resolve', params),
get: params => daemonCallWithResult('get', params),
publish: params => daemonCallWithResult('publish', params),
claim_search: params => daemonCallWithResult('claim_search', params),
claim_list: params => daemonCallWithResult('claim_list', params),
channel_create: params => daemonCallWithResult('channel_create', params),
channel_list: params => daemonCallWithResult('channel_list', params),
stream_abandon: params => daemonCallWithResult('stream_abandon', params),
channel_abandon: params => daemonCallWithResult('channel_abandon', params),
support_create: params => daemonCallWithResult('support_create', params),
// File fetching and manipulation
file_list: (params = {}) => daemonCallWithResult('file_list', params),
file_delete: (params = {}) => daemonCallWithResult('file_delete', params),
file_set_status: (params = {}) => daemonCallWithResult('file_set_status', params),
blob_delete: (params = {}) => daemonCallWithResult('blob_delete', params),
blob_list: (params = {}) => daemonCallWithResult('blob_list', params),
// Wallet utilities
account_balance: (params = {}) => daemonCallWithResult('account_balance', params),
account_decrypt: () => daemonCallWithResult('account_decrypt', {}),
account_encrypt: (params = {}) => daemonCallWithResult('account_encrypt', params),
account_unlock: (params = {}) => daemonCallWithResult('account_unlock', params),
account_list: (params = {}) => daemonCallWithResult('account_list', params),
account_send: (params = {}) => daemonCallWithResult('account_send', params),
address_is_mine: (params = {}) => daemonCallWithResult('address_is_mine', params),
address_unused: (params = {}) => daemonCallWithResult('address_unused', params),
transaction_list: (params = {}) => daemonCallWithResult('transaction_list', params),
utxo_release: (params = {}) => daemonCallWithResult('utxo_release', params),
sync_hash: (params = {}) => daemonCallWithResult('sync_hash', params),
sync_apply: (params = {}) => daemonCallWithResult('sync_apply', params),
// Connect to the sdk
connect: () => {
if (Lbry.connectPromise === null) {
Lbry.connectPromise = new Promise((resolve, reject) => {
let tryNum = 0;
// Check every half second to see if the daemon is accepting connections
function checkDaemonStarted() {
tryNum += 1;
Lbry.status().then(resolve).catch(() => {
if (tryNum <= CHECK_DAEMON_STARTED_TRY_NUMBER) {
setTimeout(checkDaemonStarted, tryNum < 50 ? 400 : 1000);
} else {
reject(new Error('Unable to connect to LBRY'));
}
});
}
checkDaemonStarted();
});
}
// Flow thinks this could be empty, but it will always reuturn a promise
// $FlowFixMe
return Lbry.connectPromise;
}
}; };
function checkAndParse(response) { function checkAndParse(response) {
@ -616,142 +718,16 @@ function apiCall(method, params, resolve, reject) {
}).catch(reject); }).catch(reject);
} }
const daemonCallWithResult = (name, params = {}) => new Promise((resolve, reject) => { function daemonCallWithResult(name, params = {}) {
return new Promise((resolve, reject) => {
apiCall(name, params, result => { apiCall(name, params, result => {
resolve(result); resolve(result);
}, reject); }, reject);
}); });
// blobs
Lbry.blob_delete = (params = {}) => daemonCallWithResult('blob_delete', params);
Lbry.blob_list = (params = {}) => daemonCallWithResult('blob_list', params);
// core
Lbry.status = (params = {}) => daemonCallWithResult('status', params);
Lbry.version = () => daemonCallWithResult('version', {});
Lbry.file_delete = (params = {}) => daemonCallWithResult('file_delete', params);
Lbry.file_set_status = (params = {}) => daemonCallWithResult('file_set_status', params);
Lbry.stop = () => daemonCallWithResult('stop', {});
// claims
Lbry.claim_list_by_channel = (params = {}) => daemonCallWithResult('claim_list_by_channel', params);
// wallet
Lbry.account_balance = (params = {}) => daemonCallWithResult('account_balance', params);
Lbry.account_decrypt = () => daemonCallWithResult('account_decrypt', {});
Lbry.account_encrypt = (params = {}) => daemonCallWithResult('account_encrypt', params);
Lbry.account_list = (params = {}) => daemonCallWithResult('account_list', params);
Lbry.address_is_mine = (params = {}) => daemonCallWithResult('address_is_mine', params);
Lbry.wallet_lock = () => daemonCallWithResult('wallet_lock', {});
Lbry.address_unused = (params = {}) => daemonCallWithResult('address_unused', params);
Lbry.wallet_send = (params = {}) => daemonCallWithResult('wallet_send', params);
Lbry.account_unlock = (params = {}) => daemonCallWithResult('account_unlock', params);
Lbry.address_unused = () => daemonCallWithResult('address_unused', {});
Lbry.claim_tip = (params = {}) => daemonCallWithResult('claim_tip', params);
// transactions
Lbry.transaction_list = (params = {}) => daemonCallWithResult('transaction_list', params);
Lbry.utxo_release = (params = {}) => daemonCallWithResult('utxo_release', params);
// sync
Lbry.sync_hash = (params = {}) => daemonCallWithResult('sync_hash', params);
Lbry.sync_apply = (params = {}) => daemonCallWithResult('sync_apply', params);
Lbry.connectPromise = null;
Lbry.connect = () => {
if (Lbry.connectPromise === null) {
Lbry.connectPromise = new Promise((resolve, reject) => {
let tryNum = 0;
// Check every half second to see if the daemon is accepting connections
function checkDaemonStarted() {
tryNum += 1;
Lbry.status().then(resolve).catch(() => {
if (tryNum <= CHECK_DAEMON_STARTED_TRY_NUMBER) {
setTimeout(checkDaemonStarted, tryNum < 50 ? 400 : 1000);
} else {
reject(new Error('Unable to connect to LBRY'));
}
});
} }
checkDaemonStarted(); // This is only for a fallback
}); // If there is a Lbry method that is being called by an app, it should be added to /flow-typed/Lbry.js
}
return Lbry.connectPromise;
};
Lbry.getMediaType = (contentType, extname) => {
if (extname) {
const formats = [[/^(mp4|m4v|webm|flv|f4v|ogv)$/i, 'video'], [/^(mp3|m4a|aac|wav|flac|ogg|opus)$/i, 'audio'], [/^(html|htm|xml|pdf|odf|doc|docx|md|markdown|txt|epub|org)$/i, 'document'], [/^(stl|obj|fbx|gcode)$/i, '3D-file']];
const res = formats.reduce((ret, testpair) => {
switch (testpair[0].test(ret)) {
case true:
return testpair[1];
default:
return ret;
}
}, extname);
return res === extname ? 'unknown' : res;
} else if (contentType) {
return (/^[^/]+/.exec(contentType)[0]
);
}
return 'unknown';
};
/**
* Wrappers for API methods to simulate missing or future behavior. Unlike the old-style stubs,
* these are designed to be transparent wrappers around the corresponding API methods.
*/
/**
* Returns results from the file_list API method, plus dummy entries for pending publishes.
* (If a real publish with the same name is found, the pending publish will be ignored and removed.)
*/
Lbry.file_list = (params = {}) => new Promise((resolve, reject) => {
apiCall('file_list', params, fileInfos => {
resolve(fileInfos);
}, reject);
});
Lbry.claim_list_mine = (params = {}) => new Promise((resolve, reject) => {
apiCall('claim_list_mine', params, claims => {
resolve(claims);
}, reject);
});
Lbry.get = (params = {}) => new Promise((resolve, reject) => {
apiCall('get', params, streamInfo => {
resolve(streamInfo);
}, reject);
});
Lbry.resolve = (params = {}) => new Promise((resolve, reject) => {
apiCall('resolve', params, data => {
resolve(data || {});
}, reject);
});
Lbry.publish = (params = {}) => new Promise((resolve, reject) => {
if (Lbry.overrides.publish) {
Lbry.overrides.publish(params).then(resolve, reject);
} else {
apiCall('publish', params, resolve, reject);
}
});
// Allow overriding Lbry methods
Lbry.overrides = {};
Lbry.setOverride = (methodName, newMethod) => {
Lbry.overrides[methodName] = newMethod;
};
// Allow overriding daemon connection string (e.g. to `/api/proxy` for lbryweb)
Lbry.setDaemonConnectionString = value => {
Lbry.daemonConnectionString = value;
};
const lbryProxy = new Proxy(Lbry, { const lbryProxy = new Proxy(Lbry, {
get(target, name) { get(target, name) {
if (name in target) { if (name in target) {
@ -1135,7 +1111,32 @@ function doDismissError() {
}; };
} }
const isClaimNsfw = claim => claim && claim.value && claim.value.stream && claim.value.stream.metadata.nsfw; var _extends$2 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
//
const naughtyTags = ['porn', 'nsfw', 'mature', 'xxx'].reduce((acc, tag) => _extends$2({}, acc, { [tag]: true }), {});
const isClaimNsfw = claim => {
if (!claim) {
throw new Error('No claim passed to isClaimNsfw()');
}
if (!claim.value) {
return false;
}
const tags = claim.value.tags || [];
for (let i = 0; i < tags.length; i += 1) {
if (naughtyTags[tags[i]]) {
return true;
}
}
return false;
};
//
const selectState$1 = state => state.claims || {}; const selectState$1 = state => state.claims || {};
@ -1225,16 +1226,20 @@ const makeSelectClaimsInChannelForCurrentPageState = uri => reselect.createSelec
}); });
const makeSelectMetadataForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => { const makeSelectMetadataForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => {
const metadata = claim && claim.value && claim.value.stream && claim.value.stream.metadata; const metadata = claim && claim.value;
return metadata || (claim === undefined ? undefined : null); return metadata || (claim === undefined ? undefined : null);
}); });
const makeSelectTitleForUri = uri => reselect.createSelector(makeSelectMetadataForUri(uri), metadata => metadata && metadata.title); const makeSelectTitleForUri = uri => reselect.createSelector(makeSelectMetadataForUri(uri), metadata => metadata && metadata.title);
const makeSelectContentTypeForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => { const makeSelectContentTypeForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => {
const source = claim && claim.value && claim.value.stream && claim.value.stream.source; const source = claim && claim.value && claim.value.source;
return source ? source.contentType : undefined; return source ? source.media_type : undefined;
});
const makeSelectThumbnailForUri = uri => reselect.createSelector(makeSelectClaimForUri(uri), claim => {
const thumbnail = claim && claim.value && claim.value.thumbnail;
return thumbnail ? thumbnail.url : undefined;
}); });
const selectIsFetchingClaimListMine = reselect.createSelector(selectState$1, state => state.isFetchingClaimListMine); const selectIsFetchingClaimListMine = reselect.createSelector(selectState$1, state => state.isFetchingClaimListMine);
@ -1293,7 +1298,7 @@ const makeSelectTotalPagesForChannel = (uri, pageSize = 10) => reselect.createSe
const makeSelectNsfwCountFromUris = uris => reselect.createSelector(selectClaimsByUri, claims => uris.reduce((acc, uri) => { const makeSelectNsfwCountFromUris = uris => reselect.createSelector(selectClaimsByUri, claims => uris.reduce((acc, uri) => {
const claim = claims[uri]; const claim = claims[uri];
if (isClaimNsfw(claim)) { if (claim && isClaimNsfw(claim)) {
return acc + 1; return acc + 1;
} }
return acc; return acc;
@ -1322,7 +1327,7 @@ const makeSelectRecommendedContentForUri = uri => reselect.createSelector(makeSe
// If we are at a vanity uri, build the full uri so we can properly filter // If we are at a vanity uri, build the full uri so we can properly filter
const currentUri = atVanityURI ? buildURI({ claimId: claim.claim_id, claimName: claim.name }) : uri; const currentUri = atVanityURI ? buildURI({ claimId: claim.claim_id, claimName: claim.name }) : uri;
const { title } = claim.value.stream.metadata; const { title } = claim.value;
const searchQuery = getSearchQueryString(title.replace(/\//, ' ')); const searchQuery = getSearchQueryString(title.replace(/\//, ' '));
@ -1339,15 +1344,16 @@ const makeSelectRecommendedContentForUri = uri => reselect.createSelector(makeSe
const makeSelectFirstRecommendedFileForUri = uri => reselect.createSelector(makeSelectRecommendedContentForUri(uri), recommendedContent => recommendedContent ? recommendedContent[0] : null); const makeSelectFirstRecommendedFileForUri = uri => reselect.createSelector(makeSelectRecommendedContentForUri(uri), recommendedContent => recommendedContent ? recommendedContent[0] : null);
// Returns the associated channel uri for a given claim uri // Returns the associated channel uri for a given claim uri
// accepts a regular claim uri lbry://something
// returns the channel uri that created this claim lbry://@channel
const makeSelectChannelForClaimUri = (uri, includePrefix = false) => reselect.createSelector(makeSelectClaimForUri(uri), claim => { const makeSelectChannelForClaimUri = (uri, includePrefix = false) => reselect.createSelector(makeSelectClaimForUri(uri), claim => {
if (!claim) { if (!claim || !claim.signing_channel) {
return null; return null;
} }
const { channel_name: channelName, value } = claim; const { claim_id: claimId, name } = claim.signing_channel;
const channelClaimId = value && value.publisherSignature && value.publisherSignature.certificateId; let channel = `${name}#${claimId}`;
return includePrefix ? `lbry://${channel}` : channel;
return channelName && channelClaimId ? buildURI({ channelName, claimId: channelClaimId }, includePrefix) : null;
}); });
const selectState$2 = state => state.wallet || {}; const selectState$2 = state => state.wallet || {};
@ -1623,7 +1629,6 @@ function doGetNewAddress() {
type: GET_NEW_ADDRESS_STARTED type: GET_NEW_ADDRESS_STARTED
}); });
// Removed localStorage use, since address is expected to be stored in redux store
lbryProxy.address_unused().then(address => { lbryProxy.address_unused().then(address => {
dispatch({ dispatch({
type: GET_NEW_ADDRESS_COMPLETED, type: GET_NEW_ADDRESS_COMPLETED,
@ -1699,8 +1704,8 @@ function doSendDraftTransaction(address, amount) {
})); }));
}; };
lbryProxy.wallet_send({ lbryProxy.account_send({
address, addresses: [address],
amount: creditsToString(amount) amount: creditsToString(amount)
}).then(successCallback, errorCallback); }).then(successCallback, errorCallback);
}; };
@ -1771,9 +1776,10 @@ function doSendTip(amount, claimId, uri, successCallback, errorCallback) {
type: SUPPORT_TRANSACTION_STARTED type: SUPPORT_TRANSACTION_STARTED
}); });
lbryProxy.claim_tip({ lbryProxy.support_create({
claim_id: claimId, claim_id: claimId,
amount: creditsToString(amount) amount: creditsToString(amount),
tip: true
}).then(success, error); }).then(success, error);
}; };
} }
@ -1879,6 +1885,8 @@ function doUpdateBlockHeight() {
}); });
} }
var _extends$3 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
function doResolveUris(uris, returnCachedClaims = false) { function doResolveUris(uris, returnCachedClaims = false) {
return (dispatch, getState) => { return (dispatch, getState) => {
const normalizedUris = uris.map(normalizeURI); const normalizedUris = uris.map(normalizeURI);
@ -1904,6 +1912,7 @@ function doResolveUris(uris, returnCachedClaims = false) {
}); });
const resolveInfo = {}; const resolveInfo = {};
lbryProxy.resolve({ urls: urisToResolve }).then(result => { lbryProxy.resolve({ urls: urisToResolve }).then(result => {
Object.entries(result).forEach(([uri, uriResolveInfo]) => { Object.entries(result).forEach(([uri, uriResolveInfo]) => {
const fallbackResolveInfo = { const fallbackResolveInfo = {
@ -1912,9 +1921,16 @@ function doResolveUris(uris, returnCachedClaims = false) {
certificate: null certificate: null
}; };
const { claim, certificate, claims_in_channel: claimsInChannel } = uriResolveInfo && !uriResolveInfo.error ? uriResolveInfo : fallbackResolveInfo; // Flow has terrible Object.entries support
// https://github.com/facebook/flow/issues/2221
// $FlowFixMe
if (uriResolveInfo.error) {
resolveInfo[uri] = _extends$3({}, fallbackResolveInfo);
} else {
// $FlowFixMe
const { claim, certificate, claims_in_channel: claimsInChannel } = uriResolveInfo;
resolveInfo[uri] = { claim, certificate, claimsInChannel }; resolveInfo[uri] = { claim, certificate, claimsInChannel };
}
}); });
dispatch({ dispatch({
@ -1935,7 +1951,7 @@ function doFetchClaimListMine() {
type: FETCH_CLAIM_LIST_MINE_STARTED type: FETCH_CLAIM_LIST_MINE_STARTED
}); });
lbryProxy.claim_list_mine().then(claims => { lbryProxy.claim_list().then(claims => {
dispatch({ dispatch({
type: FETCH_CLAIM_LIST_MINE_COMPLETED, type: FETCH_CLAIM_LIST_MINE_COMPLETED,
data: { data: {
@ -1950,7 +1966,14 @@ function doAbandonClaim(txid, nout) {
return (dispatch, getState) => { return (dispatch, getState) => {
const state = getState(); const state = getState();
const myClaims = selectMyClaimsRaw(state); const myClaims = selectMyClaimsRaw(state);
const { claim_id: claimId } = myClaims.find(claim => claim.txid === txid && claim.nout === nout); const claimToAbandon = myClaims.find(claim => claim.txid === txid && claim.nout === nout);
if (!claimToAbandon) {
console.error('No associated claim with txid: ', txid);
return;
}
const { claim_id: claimId, name: claimName } = claimToAbandon;
dispatch({ dispatch({
type: ABANDON_CLAIM_STARTED, type: ABANDON_CLAIM_STARTED,
@ -1961,50 +1984,48 @@ function doAbandonClaim(txid, nout) {
const errorCallback = () => { const errorCallback = () => {
dispatch(doToast({ dispatch(doToast({
message: 'Transaction failed', message: 'Error abandoning claim',
isError: true isError: true
})); }));
}; };
const successCallback = results => { const successCallback = () => {
if (results.success === true) {
dispatch({ dispatch({
type: ABANDON_CLAIM_SUCCEEDED, type: ABANDON_CLAIM_SUCCEEDED,
data: { data: {
claimId claimId
} }
}); });
dispatch(doToast({ dispatch(doToast({
message: 'Successfully abandoned your claim' message: 'Successfully abandoned your claim'
})); }));
// After abandoning, call claim_list_mine to show the claim as abandoned // After abandoning, call claim_list to show the claim as abandoned
// Also fetch transactions to show the new abandon transaction // Also fetch transactions to show the new abandon transaction
dispatch(doFetchClaimListMine()); dispatch(doFetchClaimListMine());
dispatch(doFetchTransactions()); dispatch(doFetchTransactions());
} else {
dispatch(doToast({
message: 'Error abandoning claim',
isError: true
}));
}
}; };
lbryProxy.claim_abandon({ const abandonParams = {
txid, txid,
nout nout,
}).then(successCallback, errorCallback); blocking: true
};
const method = claimName.startsWith('@') ? 'channel_abandon' : 'stream_abandon';
lbryProxy[method](abandonParams).then(successCallback, errorCallback);
}; };
} }
function doFetchClaimsByChannel(uri, page) { function doFetchClaimsByChannel(uri, page = 1) {
return dispatch => { return dispatch => {
dispatch({ dispatch({
type: FETCH_CHANNEL_CLAIMS_STARTED, type: FETCH_CHANNEL_CLAIMS_STARTED,
data: { uri, page } data: { uri, page }
}); });
lbryProxy.claim_list_by_channel({ uri, page: page || 1 }).then(result => { lbryProxy.claim_search({ uri, page: page || 1 }).then(result => {
const claimResult = result[uri] || {}; const claimResult = result[uri] || {};
const { claims_in_channel: claimsInChannel, returned_page: returnedPage } = claimResult; const { claims_in_channel: claimsInChannel, returned_page: returnedPage } = claimResult;
@ -2020,26 +2041,48 @@ function doFetchClaimsByChannel(uri, page) {
}; };
} }
function doFetchClaimCountByChannel(uri) { function doCreateChannel(name, amount) {
return dispatch => { return dispatch => {
dispatch({ dispatch({
type: FETCH_CHANNEL_CLAIM_COUNT_STARTED, type: CREATE_CHANNEL_STARTED
data: { uri }
}); });
lbryProxy.claim_list_by_channel({ uri }).then(result => { return lbryProxy.channel_create({
const claimResult = result[uri]; name,
const totalClaims = claimResult ? claimResult.claims_in_channel : 0; bid: creditsToString(amount)
})
// outputs[0] is the certificate
// outputs[1] is the change from the tx, not in the app currently
.then(result => {
const channelClaim = result.outputs[0];
dispatch({ dispatch({
type: FETCH_CHANNEL_CLAIM_COUNT_COMPLETED, type: CREATE_CHANNEL_COMPLETED,
data: { data: { channelClaim }
uri, });
totalClaims }).catch(error => {
dispatch({
type: CREATE_CHANNEL_FAILED,
data: error
});
});
};
} }
function doFetchChannelListMine() {
return dispatch => {
dispatch({
type: FETCH_CHANNEL_LIST_STARTED
}); });
const callback = channels => {
dispatch({
type: FETCH_CHANNEL_LIST_COMPLETED,
data: { claims: channels }
}); });
}; };
lbryProxy.channel_list().then(callback);
};
} }
const selectState$3 = state => state.fileInfo || {}; const selectState$3 = state => state.fileInfo || {};
@ -2297,6 +2340,7 @@ function debouce(func, wait, immediate) {
}; };
} }
//
function handleFetchResponse(response) { function handleFetchResponse(response) {
return response.status === 200 ? Promise.resolve(response.json()) : Promise.reject(new Error(response.statusText)); return response.status === 200 ? Promise.resolve(response.json()) : Promise.reject(new Error(response.statusText));
} }
@ -2451,10 +2495,22 @@ function savePosition(claimId, outpoint, position) {
}; };
} }
const reducers = {}; //
const reducers = {};
const defaultState = { const defaultState = {
channelClaimCounts: {} byId: {},
claimsByUri: {},
claimsByChannel: {},
channelClaimCounts: {},
fetchingChannelClaims: {},
resolvingUris: [],
// This should not be a Set
// Storing sets in reducers can cause issues
myChannelClaims: new Set(),
fetchingMyChannels: false,
abandoningById: {},
pendingById: {}
}; };
reducers[RESOLVE_URIS_COMPLETED] = (state, action) => { reducers[RESOLVE_URIS_COMPLETED] = (state, action) => {
@ -2463,28 +2519,32 @@ reducers[RESOLVE_URIS_COMPLETED] = (state, action) => {
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
const channelClaimCounts = Object.assign({}, state.channelClaimCounts); const channelClaimCounts = Object.assign({}, state.channelClaimCounts);
Object.entries(resolveInfo).forEach(([uri, { certificate, claimsInChannel }]) => { Object.entries(resolveInfo).forEach(([uri, resolveResponse]) => {
if (certificate && !Number.isNaN(claimsInChannel)) { // $FlowFixMe
channelClaimCounts[uri] = claimsInChannel; if (resolveResponse.certificate && !Number.isNaN(resolveResponse.claimsInChannel)) {
// $FlowFixMe
channelClaimCounts[uri] = resolveResponse.claimsInChannel;
} }
}); });
// $FlowFixMe
Object.entries(resolveInfo).forEach(([uri, { certificate, claim }]) => { Object.entries(resolveInfo).forEach(([uri, { certificate, claim }]) => {
if (claim) { if (claim && !certificate) {
byId[claim.claim_id] = claim; byId[claim.claim_id] = claim;
byUri[uri] = claim.claim_id; byUri[uri] = claim.claim_id;
} else if (claim === undefined && certificate !== undefined) { } else if (claim && certificate) {
byId[claim.claim_id] = claim;
byUri[uri] = claim.claim_id;
byId[certificate.claim_id] = certificate;
const channelUri = `lbry://${certificate.name}#${certificate.claim_id}`;
byUri[channelUri] = certificate.claim_id;
} else if (!claim && certificate) {
byId[certificate.claim_id] = certificate; byId[certificate.claim_id] = certificate;
// Don't point URI at the channel certificate unless it actually is
// a channel URI. This is brittle.
if (!uri.split(certificate.name)[1].match(/\//)) {
byUri[uri] = certificate.claim_id; byUri[uri] = certificate.claim_id;
} else { } else {
byUri[uri] = null; byUri[uri] = null;
} }
} else {
byUri[uri] = null;
}
}); });
return Object.assign({}, state, { return Object.assign({}, state, {
@ -2521,7 +2581,10 @@ reducers[FETCH_CLAIM_LIST_MINE_COMPLETED] = (state, action) => {
}); });
// Remove old pending publishes // Remove old pending publishes
Object.values(pendingById).filter(pendingClaim => byId[pendingClaim.claim_id]).forEach(pendingClaim => { Object.values(pendingById)
// $FlowFixMe
.filter(pendingClaim => byId[pendingClaim.claim_id]).forEach(pendingClaim => {
// $FlowFixMe
delete pendingById[pendingClaim.claim_id]; delete pendingById[pendingClaim.claim_id];
}); });
@ -2566,7 +2629,11 @@ reducers[FETCH_CHANNEL_CLAIMS_STARTED] = (state, action) => {
}; };
reducers[FETCH_CHANNEL_CLAIMS_COMPLETED] = (state, action) => { reducers[FETCH_CHANNEL_CLAIMS_COMPLETED] = (state, action) => {
const { uri, claims, page } = action.data; const {
uri,
claims,
page
} = action.data;
const claimsByChannel = Object.assign({}, state.claimsByChannel); const claimsByChannel = Object.assign({}, state.claimsByChannel);
const byChannel = Object.assign({}, claimsByChannel[uri]); const byChannel = Object.assign({}, claimsByChannel[uri]);
@ -2630,7 +2697,7 @@ reducers[ABANDON_CLAIM_SUCCEEDED] = (state, action) => {
}; };
reducers[CREATE_CHANNEL_COMPLETED] = (state, action) => { reducers[CREATE_CHANNEL_COMPLETED] = (state, action) => {
const { channelClaim } = action.data; const channelClaim = action.data.channelClaim;
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
const myChannelClaims = new Set(state.myChannelClaims); const myChannelClaims = new Set(state.myChannelClaims);
@ -2647,7 +2714,7 @@ reducers[RESOLVE_URIS_STARTED] = (state, action) => {
const { uris } = action.data; const { uris } = action.data;
const oldResolving = state.resolvingUris || []; const oldResolving = state.resolvingUris || [];
const newResolving = Object.assign([], oldResolving); const newResolving = oldResolving.slice();
uris.forEach(uri => { uris.forEach(uri => {
if (!newResolving.includes(uri)) { if (!newResolving.includes(uri)) {
@ -2660,24 +2727,13 @@ reducers[RESOLVE_URIS_STARTED] = (state, action) => {
}); });
}; };
reducers[FETCH_CHANNEL_CLAIM_COUNT_COMPLETED] = (state, action) => {
const channelClaimCounts = Object.assign({}, state.channelClaimCounts);
const { uri, totalClaims } = action.data;
channelClaimCounts[uri] = totalClaims;
return Object.assign({}, state, {
channelClaimCounts
});
};
function claimsReducer(state = defaultState, action) { function claimsReducer(state = defaultState, action) {
const handler = reducers[action.type]; const handler = reducers[action.type];
if (handler) return handler(state, action); if (handler) return handler(state, action);
return state; return state;
} }
var _extends$2 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var _extends$4 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
const reducers$1 = {}; const reducers$1 = {};
const defaultState$1 = { const defaultState$1 = {
@ -2813,12 +2869,12 @@ reducers$1[LOADING_VIDEO_STARTED] = (state, action) => {
const newLoading = Object.assign({}, state.urisLoading); const newLoading = Object.assign({}, state.urisLoading);
newLoading[uri] = true; newLoading[uri] = true;
const newErrors = _extends$2({}, state.errors); const newErrors = _extends$4({}, state.errors);
if (uri in newErrors) delete newErrors[uri]; if (uri in newErrors) delete newErrors[uri];
return Object.assign({}, state, { return Object.assign({}, state, {
urisLoading: newLoading, urisLoading: newLoading,
errors: _extends$2({}, newErrors) errors: _extends$4({}, newErrors)
}); });
}; };
@ -2828,12 +2884,12 @@ reducers$1[LOADING_VIDEO_FAILED] = (state, action) => {
const newLoading = Object.assign({}, state.urisLoading); const newLoading = Object.assign({}, state.urisLoading);
delete newLoading[uri]; delete newLoading[uri];
const newErrors = _extends$2({}, state.errors); const newErrors = _extends$4({}, state.errors);
newErrors[uri] = true; newErrors[uri] = true;
return Object.assign({}, state, { return Object.assign({}, state, {
urisLoading: newLoading, urisLoading: newLoading,
errors: _extends$2({}, newErrors) errors: _extends$4({}, newErrors)
}); });
}; };
@ -2884,7 +2940,7 @@ const handleActions = (actionMap, defaultState) => (state = defaultState, action
return state; return state;
}; };
var _extends$3 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var _extends$5 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
const defaultState$2 = { const defaultState$2 = {
notifications: [], notifications: [],
@ -2899,7 +2955,7 @@ const notificationsReducer = handleActions({
const newToasts = state.toasts.slice(); const newToasts = state.toasts.slice();
newToasts.push(toast); newToasts.push(toast);
return _extends$3({}, state, { return _extends$5({}, state, {
toasts: newToasts toasts: newToasts
}); });
}, },
@ -2907,7 +2963,7 @@ const notificationsReducer = handleActions({
const newToasts = state.toasts.slice(); const newToasts = state.toasts.slice();
newToasts.shift(); newToasts.shift();
return _extends$3({}, state, { return _extends$5({}, state, {
toasts: newToasts toasts: newToasts
}); });
}, },
@ -2918,7 +2974,7 @@ const notificationsReducer = handleActions({
const newNotifications = state.notifications.slice(); const newNotifications = state.notifications.slice();
newNotifications.push(notification); newNotifications.push(notification);
return _extends$3({}, state, { return _extends$5({}, state, {
notifications: newNotifications notifications: newNotifications
}); });
}, },
@ -2929,7 +2985,7 @@ const notificationsReducer = handleActions({
notifications = notifications.map(pastNotification => pastNotification.id === notification.id ? notification : pastNotification); notifications = notifications.map(pastNotification => pastNotification.id === notification.id ? notification : pastNotification);
return _extends$3({}, state, { return _extends$5({}, state, {
notifications notifications
}); });
}, },
@ -2938,7 +2994,7 @@ const notificationsReducer = handleActions({
let newNotifications = state.notifications.slice(); let newNotifications = state.notifications.slice();
newNotifications = newNotifications.filter(notification => notification.id !== id); newNotifications = newNotifications.filter(notification => notification.id !== id);
return _extends$3({}, state, { return _extends$5({}, state, {
notifications: newNotifications notifications: newNotifications
}); });
}, },
@ -2949,7 +3005,7 @@ const notificationsReducer = handleActions({
const newErrors = state.errors.slice(); const newErrors = state.errors.slice();
newErrors.push(error); newErrors.push(error);
return _extends$3({}, state, { return _extends$5({}, state, {
errors: newErrors errors: newErrors
}); });
}, },
@ -2957,13 +3013,13 @@ const notificationsReducer = handleActions({
const newErrors = state.errors.slice(); const newErrors = state.errors.slice();
newErrors.shift(); newErrors.shift();
return _extends$3({}, state, { return _extends$5({}, state, {
errors: newErrors errors: newErrors
}); });
} }
}, defaultState$2); }, defaultState$2);
var _extends$4 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var _extends$6 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
const defaultState$3 = { const defaultState$3 = {
isActive: false, // does the user have any typed text in the search input isActive: false, // does the user have any typed text in the search input
@ -2983,61 +3039,51 @@ const defaultState$3 = {
}; };
const searchReducer = handleActions({ const searchReducer = handleActions({
[SEARCH_START]: state => _extends$4({}, state, { [SEARCH_START]: state => _extends$6({}, state, {
searching: true searching: true
}), }),
[SEARCH_SUCCESS]: (state, action) => { [SEARCH_SUCCESS]: (state, action) => {
const { query, uris } = action.data; const { query, uris } = action.data;
return _extends$4({}, state, { return _extends$6({}, state, {
searching: false, searching: false,
urisByQuery: Object.assign({}, state.urisByQuery, { [query]: uris }) urisByQuery: Object.assign({}, state.urisByQuery, { [query]: uris })
}); });
}, },
[SEARCH_FAIL]: state => _extends$4({}, state, { [SEARCH_FAIL]: state => _extends$6({}, state, {
searching: false searching: false
}), }),
[UPDATE_SEARCH_QUERY]: (state, action) => _extends$4({}, state, { [UPDATE_SEARCH_QUERY]: (state, action) => _extends$6({}, state, {
searchQuery: action.data.query, searchQuery: action.data.query,
isActive: true isActive: true
}), }),
[UPDATE_SEARCH_SUGGESTIONS]: (state, action) => _extends$4({}, state, { [UPDATE_SEARCH_SUGGESTIONS]: (state, action) => _extends$6({}, state, {
suggestions: _extends$4({}, state.suggestions, { suggestions: _extends$6({}, state.suggestions, {
[action.data.query]: action.data.suggestions [action.data.query]: action.data.suggestions
}) })
}), }),
// clear the searchQuery on back/forward unless to search page
[HISTORY_NAVIGATE]: (state, action) => {
const { url } = action.data;
return _extends$4({}, state, {
searchQuery: url.indexOf('/search') === 0 ? url.slice(14) : '',
isActive: url.indexOf('/search') === 0,
suggestions: {}
});
},
// sets isActive to false so the uri will be populated correctly if the // sets isActive to false so the uri will be populated correctly if the
// user is on a file page. The search query will still be present on any // user is on a file page. The search query will still be present on any
// other page // other page
[DISMISS_NOTIFICATION]: state => _extends$4({}, state, { [DISMISS_NOTIFICATION]: state => _extends$6({}, state, {
isActive: false isActive: false
}), }),
[SEARCH_FOCUS]: state => _extends$4({}, state, { [SEARCH_FOCUS]: state => _extends$6({}, state, {
focused: true focused: true
}), }),
[SEARCH_BLUR]: state => _extends$4({}, state, { [SEARCH_BLUR]: state => _extends$6({}, state, {
focused: false focused: false
}), }),
[UPDATE_SEARCH_OPTIONS]: (state, action) => { [UPDATE_SEARCH_OPTIONS]: (state, action) => {
const { options: oldOptions } = state; const { options: oldOptions } = state;
const newOptions = action.data; const newOptions = action.data;
const options = _extends$4({}, oldOptions, newOptions); const options = _extends$6({}, oldOptions, newOptions);
return _extends$4({}, state, { return _extends$6({}, state, {
options options
}); });
} }
@ -3292,7 +3338,7 @@ function walletReducer(state = defaultState$4, action) {
return state; return state;
} }
var _extends$5 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var _extends$7 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
const reducers$3 = {}; const reducers$3 = {};
const defaultState$5 = { const defaultState$5 = {
@ -3301,9 +3347,9 @@ const defaultState$5 = {
reducers$3[SET_CONTENT_POSITION] = (state, action) => { reducers$3[SET_CONTENT_POSITION] = (state, action) => {
const { claimId, outpoint, position } = action.data; const { claimId, outpoint, position } = action.data;
return _extends$5({}, state, { return _extends$7({}, state, {
positions: _extends$5({}, state.positions, { positions: _extends$7({}, state.positions, {
[claimId]: _extends$5({}, state.positions[claimId], { [claimId]: _extends$7({}, state.positions[claimId], {
[outpoint]: position [outpoint]: position
}) })
}) })
@ -3327,14 +3373,14 @@ const makeSelectContentPositionForUri = uri => reselect.createSelector(selectSta
return state.positions[id] ? state.positions[id][outpoint] : null; return state.positions[id] ? state.positions[id][outpoint] : null;
}); });
var _extends$6 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; var _extends$8 = Object.assign || function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; };
const selectState$5 = state => state.notifications || {}; const selectState$5 = state => state.notifications || {};
const selectToast = reselect.createSelector(selectState$5, state => { const selectToast = reselect.createSelector(selectState$5, state => {
if (state.toasts.length) { if (state.toasts.length) {
const { id, params } = state.toasts[0]; const { id, params } = state.toasts[0];
return _extends$6({ return _extends$8({
id id
}, params); }, params);
} }
@ -3372,11 +3418,12 @@ exports.doAbandonClaim = doAbandonClaim;
exports.doBalanceSubscribe = doBalanceSubscribe; exports.doBalanceSubscribe = doBalanceSubscribe;
exports.doBlurSearchInput = doBlurSearchInput; exports.doBlurSearchInput = doBlurSearchInput;
exports.doCheckAddressIsMine = doCheckAddressIsMine; exports.doCheckAddressIsMine = doCheckAddressIsMine;
exports.doCreateChannel = doCreateChannel;
exports.doDismissError = doDismissError; exports.doDismissError = doDismissError;
exports.doDismissToast = doDismissToast; exports.doDismissToast = doDismissToast;
exports.doError = doError; exports.doError = doError;
exports.doFetchBlock = doFetchBlock; exports.doFetchBlock = doFetchBlock;
exports.doFetchClaimCountByChannel = doFetchClaimCountByChannel; exports.doFetchChannelListMine = doFetchChannelListMine;
exports.doFetchClaimListMine = doFetchClaimListMine; exports.doFetchClaimListMine = doFetchClaimListMine;
exports.doFetchClaimsByChannel = doFetchClaimsByChannel; exports.doFetchClaimsByChannel = doFetchClaimsByChannel;
exports.doFetchFileInfo = doFetchFileInfo; exports.doFetchFileInfo = doFetchFileInfo;
@ -3433,6 +3480,7 @@ exports.makeSelectPendingByUri = makeSelectPendingByUri;
exports.makeSelectQueryWithOptions = makeSelectQueryWithOptions; exports.makeSelectQueryWithOptions = makeSelectQueryWithOptions;
exports.makeSelectRecommendedContentForUri = makeSelectRecommendedContentForUri; exports.makeSelectRecommendedContentForUri = makeSelectRecommendedContentForUri;
exports.makeSelectSearchUris = makeSelectSearchUris; exports.makeSelectSearchUris = makeSelectSearchUris;
exports.makeSelectThumbnailForUri = makeSelectThumbnailForUri;
exports.makeSelectTitleForUri = makeSelectTitleForUri; exports.makeSelectTitleForUri = makeSelectTitleForUri;
exports.makeSelectTotalItemsForChannel = makeSelectTotalItemsForChannel; exports.makeSelectTotalItemsForChannel = makeSelectTotalItemsForChannel;
exports.makeSelectTotalPagesForChannel = makeSelectTotalPagesForChannel; exports.makeSelectTotalPagesForChannel = makeSelectTotalPagesForChannel;

113
dist/flow-typed/Claim.js vendored Normal file
View file

@ -0,0 +1,113 @@
// @flow
declare type ClaimWithPossibleCertificate = {
certificate?: ChannelClaim,
claim: StreamClaim,
};
declare type ChannelClaim = GenericClaim & {
value: ChannelMetadata,
};
declare type StreamClaim = GenericClaim & {
is_channel_signature_valid?: boolean,
signing_channel?: {
claim_id: string,
name: string,
value: {
public_key: string,
},
},
value: StreamMetadata,
};
declare type GenericClaim = {
address: string, // address associated with tx
amount: number, // bid amount at time of tx
claim_id: string, // unique claim identifier
claim_sequence: number,
claim_op: 'create' | 'update',
confirmations: number, // This isn't the most stable atm: https://github.com/lbryio/lbry/issues/2000
decoded_claim: boolean, // claim made in accordance with sdk protobuf types
depth: number, // confirmations since tx
effective_amount: number, // bid amount + supports
has_signature: boolean,
height: number, // block height the tx was confirmed
hex: string, // `value` hex encoded
name: string,
channel_name?: string,
normalized_name: string, // `name` normalized via unicode NFD spec,
nout: number, // index number for an output of a tx
permanent_url: string, // name + claim_id
supports: Array<{}>, // TODO: add support type once we start using it
txid: string, // unique tx id
type: 'claim' | 'update' | 'support',
valid_at_height?: number, // BUG: this should always exist https://github.com/lbryio/lbry/issues/1728
value_type: 'stream' | 'channel',
};
declare type GenericMetadata = {
title?: string,
description?: string,
thumbnail?: {
url?: string,
},
languages?: Array<string>,
tags?: Array<string>,
locations?: Array<Location>,
};
declare type ChannelMetadata = GenericMetadata & {
public_key: string,
cover_url?: string,
contact_email?: string,
homepage_url?: string,
};
declare type StreamMetadata = GenericMetadata & {
license?: string, // License "title" ex: Creative Commons, Custom copyright
license_url?: string, // Link to full license
release_time?: number, // linux timestamp
author?: string,
source: {
sd_hash: string,
media_type?: string,
hash?: string,
name?: string, // file name
size?: number, // size of file in bytes
},
// Only exists if a stream has a fee
fee?: {
amount: number, // should be a string https://github.com/lbryio/lbry/issues/1576
currency: string,
address: string,
},
stream_type: 'video' | 'audio' | 'image' | 'software',
// Below correspond to `stream_type`
video?: {
duration: number,
height: number,
width: number,
},
audio?: {
duration: number,
},
image?: {
height: number,
width: number,
},
software?: {
os: string,
},
};
declare type Location = {
latitude?: number,
longitude?: number,
country?: string,
state?: string,
code?: string,
};

35
dist/flow-typed/File.js vendored Normal file
View file

@ -0,0 +1,35 @@
// @flow
declare type FileListItem = {
metadata: StreamMetadata,
blobs_completed: number,
blobs_in_stream: number,
blobs_remaining: number,
channel_claim_id: string,
channel_name: string,
claim_id: string,
claim_name: string,
completed: false,
download_directory: string,
download_path: string,
file_name: string,
key: string,
mime_type: string,
nout: number,
outpoint: string,
points_paid: number,
protobuf: string,
sd_hash: string,
status: string,
stopped: false,
stream_hash: string,
stream_name: string,
suggested_file_name: string,
total_bytes: number,
total_bytes_lower_bound: number,
// TODO: sdk plans to change `tx`
// It isn't currently used by the apps
tx: {},
txid: string,
written_bytes: number,
};

175
dist/flow-typed/Lbry.js vendored Normal file
View file

@ -0,0 +1,175 @@
// @flow
declare type StatusResponse = {
blob_manager: {
finished_blobs: number,
},
blockchain_headers: {
download_progress: number,
downloading_headers: boolean,
},
connection_status: {
code: string,
message: string,
},
dht: {
node_id: string,
peers_in_routing_table: number,
},
hash_announcer: {
announce_queue_size: number,
},
installation_id: string,
is_running: boolean,
skipped_components: Array<string>,
startup_status: {
blob_manager: boolean,
blockchain_headers: boolean,
database: boolean,
dht: boolean,
exchange_rate_manager: boolean,
hash_announcer: boolean,
peer_protocol_server: boolean,
stream_manager: boolean,
upnp: boolean,
wallet: boolean,
},
stream_manager: {
managed_files: number,
},
upnp: {
aioupnp_version: string,
dht_redirect_set: boolean,
external_ip: string,
gateway: string,
peer_redirect_set: boolean,
redirects: {},
},
wallet: ?{
best_blockhash: string,
blocks: number,
blocks_behind: number,
is_encrypted: boolean,
is_locked: boolean,
},
};
declare type VersionResponse = {
build: string,
lbrynet_version: string,
os_release: string,
os_system: string,
platform: string,
processor: string,
python_version: string,
};
declare type ResolveResponse = {
// Keys are the url(s) passed to resolve
[string]:
| { error: {}, certificate: ChannelClaim, claims_in_channel: number }
| { error?: {}, claim: StreamClaim, certificate?: ChannelClaim },
};
declare type GetResponse = FileListItem;
declare type GenericTxResponse = {
height: number,
hex: string,
inputs: Array<{}>,
outputs: Array<{}>,
total_fee: string,
total_input: string,
total_output: string,
txid: string,
};
declare type PublishResponse = GenericTxResponse & {
// Only first value in outputs is a claim
// That's the only value we care about
outputs: Array<StreamClaim>,
};
declare type ClaimSearchResponse = {
items: Array<StreamClaim>,
page: number,
page_size: number,
page_number: number,
};
declare type ClaimListResponse = {
claims: Array<ChannelClaim | StreamClaim>,
};
declare type ChannelCreateResponse = GenericTxResponse & {
outputs: Array<ChannelClaim>,
};
declare type ChannelListResponse = Array<ChannelClaim>;
declare type FileListResponse = Array<FileListItem>;
declare type TxListResponse = Array<Transaction>;
declare type BlobListResponse = Array<string>;
declare type AccountListResponse = Array<{
id: string,
is_default: string,
ledger: string,
name: string,
seed: string,
encrypted: string,
private_key: string,
public_key: string,
address_generator: string,
modified_on: string,
}>;
//
// Types used in the generic Lbry object that is exported
//
declare type LbryTypes = {
isConnected: boolean,
connectPromise: ?Promise<any>,
connect: () => void,
daemonConnectionString: string,
setDaemonConnectionString: string => void,
overrides: { [string]: ?Function },
setOverride: (string, Function) => void,
getMediaType: (string, ?string) => string,
// Lbry Methods
stop: () => Promise<string>,
status: () => Promise<StatusResponse>,
version: () => Promise<VersionResponse>,
resolve: (params: {}) => Promise<ResolveResponse>,
get: (params: {}) => Promise<GetResponse>,
publish: (params: {}) => Promise<PublishResponse>,
claim_search: (params: {}) => Promise<ClaimSearchResponse>,
claim_list: (params?: {}) => Promise<ClaimListResponse>,
channel_create: (params: {}) => Promise<ChannelCreateResponse>,
channel_list: () => Promise<ChannelListResponse>,
stream_abandon: (params: {}) => Promise<GenericTxResponse>,
channel_abandon: (params: {}) => Promise<GenericTxResponse>,
support_create: (params: {}) => Promise<GenericTxResponse>,
// File fetching and manipulation
file_list: (params: {}) => Promise<FileListResponse>,
file_delete: (params: {}) => Promise<boolean>,
blob_delete: (params: {}) => Promise<string>,
blob_list: (params: {}) => Promise<BlobListResponse>,
// Wallet utilities
account_balance: (params: {}) => Promise<string>,
account_decrypt: (prams: {}) => Promise<boolean>,
account_encrypt: (params: {}) => Promise<boolean>,
account_unlock: (params: {}) => Promise<boolean>,
account_list: (params: {}) => Promise<AccountListResponse>,
account_send: (params: {}) => Promise<GenericTxResponse>,
address_is_mine: (params: {}) => Promise<boolean>,
address_unused: (params: {}) => Promise<string>, // New address
transaction_list: (params: {}) => Promise<TxListResponse>,
// The app shouldn't need to do this
utxo_release: () => Promise<any>,
};

View file

@ -9,7 +9,7 @@ import * as ACTIONS from 'constants/action_types';
- If they are the result of errors, use the isError flag when creating - If they are the result of errors, use the isError flag when creating
- For errors that should interrupt user behavior, use Error - For errors that should interrupt user behavior, use Error
*/ */
export type ToastParams = { declare type ToastParams = {
message: string, message: string,
title?: string, title?: string,
linkText?: string, linkText?: string,
@ -17,12 +17,12 @@ export type ToastParams = {
isError?: boolean, isError?: boolean,
}; };
export type Toast = { declare type Toast = {
id: string, id: string,
params: ToastParams, params: ToastParams,
}; };
export type DoToast = { declare type DoToast = {
type: ACTIONS.CREATE_TOAST, type: ACTIONS.CREATE_TOAST,
data: Toast, data: Toast,
}; };
@ -33,7 +33,7 @@ export type DoToast = {
- Always saved, but can be manually deleted - Always saved, but can be manually deleted
- Can happen in the background, or because of user interaction (ex: publish confirmed) - Can happen in the background, or because of user interaction (ex: publish confirmed)
*/ */
export type Notification = { declare type Notification = {
id: string, // Unique id id: string, // Unique id
dateCreated: number, dateCreated: number,
isRead: boolean, // Used to display "new" notifications that a user hasn't seen yet isRead: boolean, // Used to display "new" notifications that a user hasn't seen yet
@ -44,23 +44,19 @@ export type Notification = {
// priority?: number // priority?: number
}; };
export type DoNotification = { declare type DoNotification = {
type: ACTIONS.CREATE_NOTIFICATION, type: ACTIONS.CREATE_NOTIFICATION,
data: Notification, data: Notification,
}; };
export type DoEditNotification = { declare type DoEditNotification = {
type: ACTIONS.EDIT_NOTIFICATION, type: ACTIONS.EDIT_NOTIFICATION,
data: { data: {
id: string, notification: Notification,
isRead: boolean,
// In the future we can add `isDismissed` if we decide to show notifications as they come in
// Similar to Facebook's notifications in the corner of the screen
// isDismissed: boolean,
}, },
}; };
export type DoDeleteNotification = { declare type DoDeleteNotification = {
type: ACTIONS.DELETE_NOTIFICATION, type: ACTIONS.DELETE_NOTIFICATION,
data: { data: {
id: string, // The id to delete id: string, // The id to delete
@ -73,25 +69,25 @@ export type DoDeleteNotification = {
- Errors that should interupt user behavior - Errors that should interupt user behavior
- For errors that can be shown without interrupting a user, use Toast with the isError flag - For errors that can be shown without interrupting a user, use Toast with the isError flag
*/ */
export type Error = { declare type ErrorNotification = {
title: string, title: string,
text: string, text: string,
}; };
export type DoError = { declare type DoError = {
type: ACTIONS.CREATE_ERROR, type: ACTIONS.CREATE_ERROR,
data: Error, data: ErrorNotification,
}; };
export type DoDismissError = { declare type DoDismissError = {
type: ACTIONS.DISMISS_ERROR, type: ACTIONS.DISMISS_ERROR,
}; };
/* /*
NotificationState NotificationState
*/ */
export type NotificationState = { declare type NotificationState = {
notifications: Array<Notification>, notifications: Array<Notification>,
errors: Array<Error>, errors: Array<ErrorNotification>,
toasts: Array<Toast>, toasts: Array<Toast>,
}; };

6
dist/flow-typed/Redux.js vendored Normal file
View file

@ -0,0 +1,6 @@
// @flow
/* eslint-disable no-use-before-define */
declare type GetState = () => any;
declare type ThunkAction = (dispatch: Dispatch, getState: GetState) => any;
declare type Dispatch = (action: {} | Promise<*> | Array<{}> | ThunkAction) => any; // Need to refer to ThunkAction
/* eslint-enable */

View file

@ -1,13 +1,13 @@
// @flow // @flow
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
export type SearchSuggestion = { declare type SearchSuggestion = {
value: string, value: string,
shorthand: string, shorthand: string,
type: string, type: string,
}; };
export type SearchOptions = { declare type SearchOptions = {
// :( // :(
// https://github.com/facebook/flow/issues/6492 // https://github.com/facebook/flow/issues/6492
RESULT_COUNT: number, RESULT_COUNT: number,
@ -22,7 +22,7 @@ export type SearchOptions = {
MEDIA_APPLICATION: string, MEDIA_APPLICATION: string,
}; };
export type SearchState = { declare type SearchState = {
isActive: boolean, isActive: boolean,
searchQuery: string, searchQuery: string,
options: SearchOptions, options: SearchOptions,
@ -30,7 +30,7 @@ export type SearchState = {
urisByQuery: {}, urisByQuery: {},
}; };
export type SearchSuccess = { declare type SearchSuccess = {
type: ACTIONS.SEARCH_SUCCESS, type: ACTIONS.SEARCH_SUCCESS,
data: { data: {
query: string, query: string,
@ -38,14 +38,14 @@ export type SearchSuccess = {
}, },
}; };
export type UpdateSearchQuery = { declare type UpdateSearchQuery = {
type: ACTIONS.UPDATE_SEARCH_QUERY, type: ACTIONS.UPDATE_SEARCH_QUERY,
data: { data: {
query: string, query: string,
}, },
}; };
export type UpdateSearchSuggestions = { declare type UpdateSearchSuggestions = {
type: ACTIONS.UPDATE_SEARCH_SUGGESTIONS, type: ACTIONS.UPDATE_SEARCH_SUGGESTIONS,
data: { data: {
query: string, query: string,
@ -53,16 +53,7 @@ export type UpdateSearchSuggestions = {
}, },
}; };
export type HistoryNavigate = { declare type UpdateSearchOptions = {
type: ACTIONS.HISTORY_NAVIGATE,
data: {
url: string,
index?: number,
scrollY?: number,
},
};
export type UpdateSearchOptions = {
type: ACTIONS.UPDATE_SEARCH_OPTIONS, type: ACTIONS.UPDATE_SEARCH_OPTIONS,
data: SearchOptions, data: SearchOptions,
}; };

11
dist/flow-typed/Transaction.js vendored Normal file
View file

@ -0,0 +1,11 @@
// @flow
declare type Transaction = {
amount: number,
claim_id: string,
claim_name: string,
fee: number,
nout: number,
txid: string,
type: string,
date: Date,
};

234
dist/flow-typed/npm/babel-core_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,234 @@
// flow-typed signature: 0f3ee620f0bd9a317baba1570b7f9328
// flow-typed version: <<STUB>>/babel-core_v^6.26.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-core'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-core' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-core/lib/api/browser' {
declare module.exports: any;
}
declare module 'babel-core/lib/api/node' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/get-possible-plugin-names' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/get-possible-preset-names' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/merge' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/normalize-ast' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve-from-possible-names' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve-plugin' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve-preset' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve' {
declare module.exports: any;
}
declare module 'babel-core/lib/store' {
declare module.exports: any;
}
declare module 'babel-core/lib/tools/build-external-helpers' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/index' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/logger' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/merge-map' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/metadata' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/build-config-chain' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/config' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/index' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/option-manager' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/parsers' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/removed' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/internal-plugins/block-hoist' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/internal-plugins/shadow-functions' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/pipeline' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/plugin-pass' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/plugin' {
declare module.exports: any;
}
declare module 'babel-core/lib/util' {
declare module.exports: any;
}
declare module 'babel-core/register' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-core/index' {
declare module.exports: $Exports<'babel-core'>;
}
declare module 'babel-core/index.js' {
declare module.exports: $Exports<'babel-core'>;
}
declare module 'babel-core/lib/api/browser.js' {
declare module.exports: $Exports<'babel-core/lib/api/browser'>;
}
declare module 'babel-core/lib/api/node.js' {
declare module.exports: $Exports<'babel-core/lib/api/node'>;
}
declare module 'babel-core/lib/helpers/get-possible-plugin-names.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/get-possible-plugin-names'>;
}
declare module 'babel-core/lib/helpers/get-possible-preset-names.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/get-possible-preset-names'>;
}
declare module 'babel-core/lib/helpers/merge.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/merge'>;
}
declare module 'babel-core/lib/helpers/normalize-ast.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/normalize-ast'>;
}
declare module 'babel-core/lib/helpers/resolve-from-possible-names.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve-from-possible-names'>;
}
declare module 'babel-core/lib/helpers/resolve-plugin.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve-plugin'>;
}
declare module 'babel-core/lib/helpers/resolve-preset.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve-preset'>;
}
declare module 'babel-core/lib/helpers/resolve.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve'>;
}
declare module 'babel-core/lib/store.js' {
declare module.exports: $Exports<'babel-core/lib/store'>;
}
declare module 'babel-core/lib/tools/build-external-helpers.js' {
declare module.exports: $Exports<'babel-core/lib/tools/build-external-helpers'>;
}
declare module 'babel-core/lib/transformation/file/index.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/index'>;
}
declare module 'babel-core/lib/transformation/file/logger.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/logger'>;
}
declare module 'babel-core/lib/transformation/file/merge-map.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/merge-map'>;
}
declare module 'babel-core/lib/transformation/file/metadata.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/metadata'>;
}
declare module 'babel-core/lib/transformation/file/options/build-config-chain.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/build-config-chain'>;
}
declare module 'babel-core/lib/transformation/file/options/config.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/config'>;
}
declare module 'babel-core/lib/transformation/file/options/index.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/index'>;
}
declare module 'babel-core/lib/transformation/file/options/option-manager.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/option-manager'>;
}
declare module 'babel-core/lib/transformation/file/options/parsers.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/parsers'>;
}
declare module 'babel-core/lib/transformation/file/options/removed.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/removed'>;
}
declare module 'babel-core/lib/transformation/internal-plugins/block-hoist.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/internal-plugins/block-hoist'>;
}
declare module 'babel-core/lib/transformation/internal-plugins/shadow-functions.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/internal-plugins/shadow-functions'>;
}
declare module 'babel-core/lib/transformation/pipeline.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/pipeline'>;
}
declare module 'babel-core/lib/transformation/plugin-pass.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/plugin-pass'>;
}
declare module 'babel-core/lib/transformation/plugin.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/plugin'>;
}
declare module 'babel-core/lib/util.js' {
declare module.exports: $Exports<'babel-core/lib/util'>;
}
declare module 'babel-core/register.js' {
declare module.exports: $Exports<'babel-core/register'>;
}

View file

@ -0,0 +1,123 @@
// flow-typed signature: bc167658b3892d915f873ecc31946cba
// flow-typed version: <<STUB>>/babel-eslint_v^8.0.3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-eslint'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-eslint' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-eslint/lib/analyze-scope' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/attachComments' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertComments' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertTemplateType' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/index' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/toAST' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/toToken' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/toTokens' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/index' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/parse-with-patch' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/parse-with-scope' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/parse' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/patch-eslint-scope' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/visitor-keys' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-eslint/lib/analyze-scope.js' {
declare module.exports: $Exports<'babel-eslint/lib/analyze-scope'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/attachComments.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/attachComments'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertComments.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/convertComments'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertTemplateType.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/convertTemplateType'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/index.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/index'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/toAST.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/toAST'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/toToken.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/toToken'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/toTokens.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/toTokens'>;
}
declare module 'babel-eslint/lib/index.js' {
declare module.exports: $Exports<'babel-eslint/lib/index'>;
}
declare module 'babel-eslint/lib/parse-with-patch.js' {
declare module.exports: $Exports<'babel-eslint/lib/parse-with-patch'>;
}
declare module 'babel-eslint/lib/parse-with-scope.js' {
declare module.exports: $Exports<'babel-eslint/lib/parse-with-scope'>;
}
declare module 'babel-eslint/lib/parse.js' {
declare module.exports: $Exports<'babel-eslint/lib/parse'>;
}
declare module 'babel-eslint/lib/patch-eslint-scope.js' {
declare module.exports: $Exports<'babel-eslint/lib/patch-eslint-scope'>;
}
declare module 'babel-eslint/lib/visitor-keys.js' {
declare module.exports: $Exports<'babel-eslint/lib/visitor-keys'>;
}

View file

@ -0,0 +1,67 @@
// flow-typed signature: ac35c8b7c7b43815c9bfe7048b1f036b
// flow-typed version: <<STUB>>/babel-loader_v^7.1.4/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-loader'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-loader' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-loader/lib/fs-cache' {
declare module.exports: any;
}
declare module 'babel-loader/lib/index' {
declare module.exports: any;
}
declare module 'babel-loader/lib/resolve-rc' {
declare module.exports: any;
}
declare module 'babel-loader/lib/utils/exists' {
declare module.exports: any;
}
declare module 'babel-loader/lib/utils/read' {
declare module.exports: any;
}
declare module 'babel-loader/lib/utils/relative' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-loader/lib/fs-cache.js' {
declare module.exports: $Exports<'babel-loader/lib/fs-cache'>;
}
declare module 'babel-loader/lib/index.js' {
declare module.exports: $Exports<'babel-loader/lib/index'>;
}
declare module 'babel-loader/lib/resolve-rc.js' {
declare module.exports: $Exports<'babel-loader/lib/resolve-rc'>;
}
declare module 'babel-loader/lib/utils/exists.js' {
declare module.exports: $Exports<'babel-loader/lib/utils/exists'>;
}
declare module 'babel-loader/lib/utils/read.js' {
declare module.exports: $Exports<'babel-loader/lib/utils/read'>;
}
declare module 'babel-loader/lib/utils/relative.js' {
declare module.exports: $Exports<'babel-loader/lib/utils/relative'>;
}

View file

@ -0,0 +1,81 @@
// flow-typed signature: ef8e8ad61abd95bef9ea072c0bdb3d98
// flow-typed version: <<STUB>>/babel-plugin-module-resolver_v^3.0.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-plugin-module-resolver'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-plugin-module-resolver' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-plugin-module-resolver/lib/index' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/log' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/mapToRelative' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/normalizeOptions' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/resolvePath' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/transformers/call' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/transformers/import' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/utils' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-plugin-module-resolver/lib/index.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/index'>;
}
declare module 'babel-plugin-module-resolver/lib/log.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/log'>;
}
declare module 'babel-plugin-module-resolver/lib/mapToRelative.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/mapToRelative'>;
}
declare module 'babel-plugin-module-resolver/lib/normalizeOptions.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/normalizeOptions'>;
}
declare module 'babel-plugin-module-resolver/lib/resolvePath.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/resolvePath'>;
}
declare module 'babel-plugin-module-resolver/lib/transformers/call.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/transformers/call'>;
}
declare module 'babel-plugin-module-resolver/lib/transformers/import.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/transformers/import'>;
}
declare module 'babel-plugin-module-resolver/lib/utils.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/utils'>;
}

View file

@ -0,0 +1,32 @@
// flow-typed signature: acec4d6ed4d2870478d3cbe333f79115
// flow-typed version: <<STUB>>/babel-plugin-transform-flow-comments_v^6.17.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-plugin-transform-flow-comments'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-plugin-transform-flow-comments' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-plugin-transform-flow-comments/lib/index' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-plugin-transform-flow-comments/lib/index.js' {
declare module.exports: $Exports<'babel-plugin-transform-flow-comments/lib/index'>;
}

View file

@ -0,0 +1,88 @@
// flow-typed signature: 1a890b0eb44450a184610ef421a6c13a
// flow-typed version: <<STUB>>/babel-preset-env_v^1.6.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-preset-env'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-preset-env' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-preset-env/data/built-in-features' {
declare module.exports: any;
}
declare module 'babel-preset-env/data/plugin-features' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/default-includes' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/index' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/module-transformations' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/normalize-options' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/targets-parser' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/transform-polyfill-require-plugin' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/utils' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-preset-env/data/built-in-features.js' {
declare module.exports: $Exports<'babel-preset-env/data/built-in-features'>;
}
declare module 'babel-preset-env/data/plugin-features.js' {
declare module.exports: $Exports<'babel-preset-env/data/plugin-features'>;
}
declare module 'babel-preset-env/lib/default-includes.js' {
declare module.exports: $Exports<'babel-preset-env/lib/default-includes'>;
}
declare module 'babel-preset-env/lib/index.js' {
declare module.exports: $Exports<'babel-preset-env/lib/index'>;
}
declare module 'babel-preset-env/lib/module-transformations.js' {
declare module.exports: $Exports<'babel-preset-env/lib/module-transformations'>;
}
declare module 'babel-preset-env/lib/normalize-options.js' {
declare module.exports: $Exports<'babel-preset-env/lib/normalize-options'>;
}
declare module 'babel-preset-env/lib/targets-parser.js' {
declare module.exports: $Exports<'babel-preset-env/lib/targets-parser'>;
}
declare module 'babel-preset-env/lib/transform-polyfill-require-plugin.js' {
declare module.exports: $Exports<'babel-preset-env/lib/transform-polyfill-require-plugin'>;
}
declare module 'babel-preset-env/lib/utils.js' {
declare module.exports: $Exports<'babel-preset-env/lib/utils'>;
}

View file

@ -0,0 +1,32 @@
// flow-typed signature: 3ebdc081e66800c1a33e3acb6581ff3c
// flow-typed version: <<STUB>>/babel-preset-stage-2_v^6.18.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-preset-stage-2'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-preset-stage-2' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-preset-stage-2/lib/index' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-preset-stage-2/lib/index.js' {
declare module.exports: $Exports<'babel-preset-stage-2/lib/index'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: 68331cab0e933e8a4092d45cad04cdea
// flow-typed version: <<STUB>>/eslint-config-standard-jsx_v^6.0.2/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-config-standard-jsx'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-config-standard-jsx' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'eslint-config-standard-jsx/index' {
declare module.exports: $Exports<'eslint-config-standard-jsx'>;
}
declare module 'eslint-config-standard-jsx/index.js' {
declare module.exports: $Exports<'eslint-config-standard-jsx'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: b7df2bd0c8381e6822c8dd629b61d47b
// flow-typed version: <<STUB>>/eslint-config-standard_v^12.0.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-config-standard'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-config-standard' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'eslint-config-standard/index' {
declare module.exports: $Exports<'eslint-config-standard'>;
}
declare module 'eslint-config-standard/index.js' {
declare module.exports: $Exports<'eslint-config-standard'>;
}

View file

@ -0,0 +1,424 @@
// flow-typed signature: 78b00087ab3122dabc1f491e91e21dc3
// flow-typed version: <<STUB>>/eslint-plugin-flowtype_v^2.46.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-flowtype'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-flowtype' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-flowtype/bin/readmeAssertions' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/isSimpleType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/needWrap' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleComplexType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleSimpleType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/booleanStyle' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/defineFlowType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/delimiterDangle' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/genericSpacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/newlineAfterFlowAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noDupeKeys' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noExistentialType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noFlowFixMeComments' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noMutableArray' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noPrimitiveConstructorTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noTypesMissingFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noUnusedExpressions' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noWeakTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/objectTypeDelimiter' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireExactType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireParameterType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireReturnType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireTypesAtTop' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireValidFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireVariableType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/semi' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/sortKeys' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceAfterTypeColon' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeGenericBracket' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeTypeColon' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateFunctions' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeIndexer' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeProperty' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateReturnType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypeCastExpression' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypical' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateVariables' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/reporter' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeIdMatch' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeImportStyle' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/unionIntersectionSpacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/useFlowType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/validSyntax' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/checkFlowFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/fuzzyStringMatch' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getParameterName' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenAfterParens' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenBeforeParens' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFile' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/quoteName' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/spacingFixers' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-flowtype/bin/readmeAssertions.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/bin/readmeAssertions'>;
}
declare module 'eslint-plugin-flowtype/dist/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/index'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyle/index'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/isSimpleType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyle/isSimpleType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/needWrap.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyle/needWrap'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleComplexType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyleComplexType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleSimpleType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyleSimpleType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/booleanStyle.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/booleanStyle'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/defineFlowType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/defineFlowType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/delimiterDangle.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/delimiterDangle'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/genericSpacing.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/genericSpacing'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/newlineAfterFlowAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/newlineAfterFlowAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noDupeKeys.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noDupeKeys'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noExistentialType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noExistentialType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noFlowFixMeComments.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noFlowFixMeComments'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noMutableArray.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noMutableArray'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noPrimitiveConstructorTypes.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noPrimitiveConstructorTypes'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noTypesMissingFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noTypesMissingFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noUnusedExpressions.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noUnusedExpressions'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noWeakTypes.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noWeakTypes'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/objectTypeDelimiter.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/objectTypeDelimiter'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireExactType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireExactType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireParameterType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireParameterType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireReturnType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireReturnType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireTypesAtTop.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireTypesAtTop'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireValidFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireValidFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireVariableType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireVariableType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/semi.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/semi'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/sortKeys.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/sortKeys'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceAfterTypeColon.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/spaceAfterTypeColon'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeGenericBracket.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/spaceBeforeGenericBracket'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeTypeColon.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/spaceBeforeTypeColon'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateFunctions.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateFunctions'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeIndexer.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeIndexer'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeProperty.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeProperty'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateReturnType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateReturnType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypeCastExpression.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypeCastExpression'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypical.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypical'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateVariables.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateVariables'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/index'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/reporter.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/reporter'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeIdMatch.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeIdMatch'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeImportStyle.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeImportStyle'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/unionIntersectionSpacing.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/unionIntersectionSpacing'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/useFlowType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/useFlowType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/validSyntax.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/validSyntax'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/checkFlowFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/checkFlowFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/fuzzyStringMatch.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/fuzzyStringMatch'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getParameterName.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/getParameterName'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenAfterParens.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/getTokenAfterParens'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenBeforeParens.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/getTokenBeforeParens'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/index'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFile.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isFlowFile'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/quoteName.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/quoteName'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/spacingFixers.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/spacingFixers'>;
}

View file

@ -0,0 +1,417 @@
// flow-typed signature: cc9510b23781c7e4a1d9ea9482254922
// flow-typed version: <<STUB>>/eslint-plugin-import_v^2.17.2/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-import'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-import' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-import/config/electron' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/errors' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/react-native' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/react' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/recommended' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/stage-0' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/typescript' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/warnings' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/core/importType' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/core/staticRequire' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/docsUrl' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/ExportMap' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/importDeclaration' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/default' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/dynamic-import-chunkname' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/exports-last' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/extensions' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/first' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/group-exports' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/imports-first' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/max-dependencies' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/named' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/namespace' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/newline-after-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-absolute-path' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-amd' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-anonymous-default-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-commonjs' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-cycle' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-default-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-deprecated' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-duplicates' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-dynamic-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-extraneous-dependencies' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-internal-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-mutable-exports' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default-member' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-default' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-namespace' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-nodejs-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-relative-parent-imports' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-restricted-paths' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-self-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-unassigned-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-unresolved' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-unused-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-useless-path-segments' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-webpack-loader-syntax' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/order' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/prefer-default-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/unambiguous' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/memo-parser/index' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-import/config/electron.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/electron'>;
}
declare module 'eslint-plugin-import/config/errors.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/errors'>;
}
declare module 'eslint-plugin-import/config/react-native.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/react-native'>;
}
declare module 'eslint-plugin-import/config/react.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/react'>;
}
declare module 'eslint-plugin-import/config/recommended.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/recommended'>;
}
declare module 'eslint-plugin-import/config/stage-0.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/stage-0'>;
}
declare module 'eslint-plugin-import/config/typescript.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/typescript'>;
}
declare module 'eslint-plugin-import/config/warnings.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/warnings'>;
}
declare module 'eslint-plugin-import/lib/core/importType.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/core/importType'>;
}
declare module 'eslint-plugin-import/lib/core/staticRequire.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/core/staticRequire'>;
}
declare module 'eslint-plugin-import/lib/docsUrl.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/docsUrl'>;
}
declare module 'eslint-plugin-import/lib/ExportMap.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/ExportMap'>;
}
declare module 'eslint-plugin-import/lib/importDeclaration.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/importDeclaration'>;
}
declare module 'eslint-plugin-import/lib/index.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/index'>;
}
declare module 'eslint-plugin-import/lib/rules/default.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/default'>;
}
declare module 'eslint-plugin-import/lib/rules/dynamic-import-chunkname.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/dynamic-import-chunkname'>;
}
declare module 'eslint-plugin-import/lib/rules/export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/export'>;
}
declare module 'eslint-plugin-import/lib/rules/exports-last.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/exports-last'>;
}
declare module 'eslint-plugin-import/lib/rules/extensions.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/extensions'>;
}
declare module 'eslint-plugin-import/lib/rules/first.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/first'>;
}
declare module 'eslint-plugin-import/lib/rules/group-exports.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/group-exports'>;
}
declare module 'eslint-plugin-import/lib/rules/imports-first.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/imports-first'>;
}
declare module 'eslint-plugin-import/lib/rules/max-dependencies.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/max-dependencies'>;
}
declare module 'eslint-plugin-import/lib/rules/named.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/named'>;
}
declare module 'eslint-plugin-import/lib/rules/namespace.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/namespace'>;
}
declare module 'eslint-plugin-import/lib/rules/newline-after-import.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/newline-after-import'>;
}
declare module 'eslint-plugin-import/lib/rules/no-absolute-path.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-absolute-path'>;
}
declare module 'eslint-plugin-import/lib/rules/no-amd.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-amd'>;
}
declare module 'eslint-plugin-import/lib/rules/no-anonymous-default-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-anonymous-default-export'>;
}
declare module 'eslint-plugin-import/lib/rules/no-commonjs.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-commonjs'>;
}
declare module 'eslint-plugin-import/lib/rules/no-cycle.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-cycle'>;
}
declare module 'eslint-plugin-import/lib/rules/no-default-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-default-export'>;
}
declare module 'eslint-plugin-import/lib/rules/no-deprecated.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-deprecated'>;
}
declare module 'eslint-plugin-import/lib/rules/no-duplicates.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-duplicates'>;
}
declare module 'eslint-plugin-import/lib/rules/no-dynamic-require.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-dynamic-require'>;
}
declare module 'eslint-plugin-import/lib/rules/no-extraneous-dependencies.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-extraneous-dependencies'>;
}
declare module 'eslint-plugin-import/lib/rules/no-internal-modules.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-internal-modules'>;
}
declare module 'eslint-plugin-import/lib/rules/no-mutable-exports.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-mutable-exports'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default-member.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-as-default-member'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-as-default'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-default.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-default'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-export'>;
}
declare module 'eslint-plugin-import/lib/rules/no-namespace.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-namespace'>;
}
declare module 'eslint-plugin-import/lib/rules/no-nodejs-modules.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-nodejs-modules'>;
}
declare module 'eslint-plugin-import/lib/rules/no-relative-parent-imports.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-relative-parent-imports'>;
}
declare module 'eslint-plugin-import/lib/rules/no-restricted-paths.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-restricted-paths'>;
}
declare module 'eslint-plugin-import/lib/rules/no-self-import.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-self-import'>;
}
declare module 'eslint-plugin-import/lib/rules/no-unassigned-import.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-unassigned-import'>;
}
declare module 'eslint-plugin-import/lib/rules/no-unresolved.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-unresolved'>;
}
declare module 'eslint-plugin-import/lib/rules/no-unused-modules.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-unused-modules'>;
}
declare module 'eslint-plugin-import/lib/rules/no-useless-path-segments.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-useless-path-segments'>;
}
declare module 'eslint-plugin-import/lib/rules/no-webpack-loader-syntax.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-webpack-loader-syntax'>;
}
declare module 'eslint-plugin-import/lib/rules/order.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/order'>;
}
declare module 'eslint-plugin-import/lib/rules/prefer-default-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/prefer-default-export'>;
}
declare module 'eslint-plugin-import/lib/rules/unambiguous.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/unambiguous'>;
}
declare module 'eslint-plugin-import/memo-parser/index.js' {
declare module.exports: $Exports<'eslint-plugin-import/memo-parser/index'>;
}

View file

@ -0,0 +1,333 @@
// flow-typed signature: a4fea72b146e0dd4b94dcadb805fd976
// flow-typed version: <<STUB>>/eslint-plugin-node_v^8.0.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-node'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-node' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-node/lib/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/exports-style' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-deprecated-api' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-hide-core-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-bin' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-builtins' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-syntax' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/node-builtins' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/buffer' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/console' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/process' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-decoder' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-encoder' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url-search-params' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/process-exit-as-throw' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/shebang' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/cache' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-existence' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-extraneous' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-prefer-global' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-publish' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-unsupported-builtins' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/enumerate-property-names' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/exists' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-allow-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-configured-node-version' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-convert-path' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-import-export-targets' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-npmignore' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-package-json' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-require-targets' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-resolve-paths' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-semver-range' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-try-extensions' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/import-target' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/strip-import-path-params' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-node/lib/index.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/index'>;
}
declare module 'eslint-plugin-node/lib/rules/exports-style.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/exports-style'>;
}
declare module 'eslint-plugin-node/lib/rules/no-deprecated-api.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-deprecated-api'>;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-import.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-extraneous-import'>;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-require.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-extraneous-require'>;
}
declare module 'eslint-plugin-node/lib/rules/no-hide-core-modules.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-hide-core-modules'>;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-import.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-missing-import'>;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-require.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-missing-require'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-bin.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unpublished-bin'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-import.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unpublished-import'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-require.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unpublished-require'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-builtins.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features/es-builtins'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-syntax.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features/es-syntax'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/node-builtins.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features/node-builtins'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/buffer.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/buffer'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/console.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/console'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/process.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/process'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-decoder.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/text-decoder'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-encoder.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/text-encoder'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url-search-params.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/url-search-params'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/url'>;
}
declare module 'eslint-plugin-node/lib/rules/process-exit-as-throw.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/process-exit-as-throw'>;
}
declare module 'eslint-plugin-node/lib/rules/shebang.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/shebang'>;
}
declare module 'eslint-plugin-node/lib/util/cache.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/cache'>;
}
declare module 'eslint-plugin-node/lib/util/check-existence.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-existence'>;
}
declare module 'eslint-plugin-node/lib/util/check-extraneous.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-extraneous'>;
}
declare module 'eslint-plugin-node/lib/util/check-prefer-global.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-prefer-global'>;
}
declare module 'eslint-plugin-node/lib/util/check-publish.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-publish'>;
}
declare module 'eslint-plugin-node/lib/util/check-unsupported-builtins.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-unsupported-builtins'>;
}
declare module 'eslint-plugin-node/lib/util/enumerate-property-names.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/enumerate-property-names'>;
}
declare module 'eslint-plugin-node/lib/util/exists.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/exists'>;
}
declare module 'eslint-plugin-node/lib/util/get-allow-modules.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-allow-modules'>;
}
declare module 'eslint-plugin-node/lib/util/get-configured-node-version.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-configured-node-version'>;
}
declare module 'eslint-plugin-node/lib/util/get-convert-path.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-convert-path'>;
}
declare module 'eslint-plugin-node/lib/util/get-import-export-targets.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-import-export-targets'>;
}
declare module 'eslint-plugin-node/lib/util/get-npmignore.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-npmignore'>;
}
declare module 'eslint-plugin-node/lib/util/get-package-json.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-package-json'>;
}
declare module 'eslint-plugin-node/lib/util/get-require-targets.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-require-targets'>;
}
declare module 'eslint-plugin-node/lib/util/get-resolve-paths.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-resolve-paths'>;
}
declare module 'eslint-plugin-node/lib/util/get-semver-range.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-semver-range'>;
}
declare module 'eslint-plugin-node/lib/util/get-try-extensions.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-try-extensions'>;
}
declare module 'eslint-plugin-node/lib/util/import-target.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/import-target'>;
}
declare module 'eslint-plugin-node/lib/util/strip-import-path-params.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/strip-import-path-params'>;
}

View file

@ -0,0 +1,185 @@
// flow-typed signature: dd15a042fcd40a1d0e6f424e827085b5
// flow-typed version: <<STUB>>/eslint-plugin-promise_v^4.1.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-promise'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-promise' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-promise/rules/always-return' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/avoid-new' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/catch-or-return' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/get-docs-url' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/has-promise-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-promise' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-named-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-promise' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/promise-statics' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-callback-in-promise' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-native' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-nesting' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-new-statics' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-promise-in-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-return-in-finally' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-return-wrap' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/param-names' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-callbacks' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-then' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/valid-params' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-promise/index' {
declare module.exports: $Exports<'eslint-plugin-promise'>;
}
declare module 'eslint-plugin-promise/index.js' {
declare module.exports: $Exports<'eslint-plugin-promise'>;
}
declare module 'eslint-plugin-promise/rules/always-return.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/always-return'>;
}
declare module 'eslint-plugin-promise/rules/avoid-new.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/avoid-new'>;
}
declare module 'eslint-plugin-promise/rules/catch-or-return.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/catch-or-return'>;
}
declare module 'eslint-plugin-promise/rules/lib/get-docs-url.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/get-docs-url'>;
}
declare module 'eslint-plugin-promise/rules/lib/has-promise-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/has-promise-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-inside-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-promise.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-inside-promise'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-named-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-named-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-promise.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-promise'>;
}
declare module 'eslint-plugin-promise/rules/lib/promise-statics.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/promise-statics'>;
}
declare module 'eslint-plugin-promise/rules/no-callback-in-promise.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-callback-in-promise'>;
}
declare module 'eslint-plugin-promise/rules/no-native.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-native'>;
}
declare module 'eslint-plugin-promise/rules/no-nesting.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-nesting'>;
}
declare module 'eslint-plugin-promise/rules/no-new-statics.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-new-statics'>;
}
declare module 'eslint-plugin-promise/rules/no-promise-in-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-promise-in-callback'>;
}
declare module 'eslint-plugin-promise/rules/no-return-in-finally.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-return-in-finally'>;
}
declare module 'eslint-plugin-promise/rules/no-return-wrap.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-return-wrap'>;
}
declare module 'eslint-plugin-promise/rules/param-names.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/param-names'>;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-callbacks.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/prefer-await-to-callbacks'>;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-then.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/prefer-await-to-then'>;
}
declare module 'eslint-plugin-promise/rules/valid-params.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/valid-params'>;
}

View file

@ -0,0 +1,696 @@
// flow-typed signature: fc9dc51418188f7754f08351c66422d6
// flow-typed version: <<STUB>>/eslint-plugin-react_v^7.12.4/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-react'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-react' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-react/lib/rules/boolean-prop-naming' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/button-has-type' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/default-props-match-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/destructuring-assignment' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/display-name' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-component-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-dom-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-elements' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-foreign-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-boolean-value' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-child-element-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-bracket-location' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-tag-location' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-brace-presence' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-equals-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-filename-extension' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-first-prop-new-line' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-fragments' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-handler-names' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-key' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-depth' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-props-per-line' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-bind' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-comment-textnodes' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-duplicate-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-literals' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-target-blank' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-undef' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-one-expression-per-line' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-pascal-case' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-props-no-multi-spaces' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-default-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-space-before-closing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-tag-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-react' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-vars' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-wrap-multilines' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-access-state-in-setstate' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-array-index-key' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-children-prop' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-danger-with-children' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-danger' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-deprecated' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-did-mount-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-did-update-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-direct-mutation-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-find-dom-node' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-is-mounted' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-multi-comp' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-redundant-should-component-update' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-render-return-value' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-string-refs' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-this-in-sfc' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-typos' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unescaped-entities' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unknown-property' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unsafe' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-will-update-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/prefer-es6-class' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/prefer-stateless-function' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/react-in-jsx-scope' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/require-default-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/require-optimization' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/require-render-return' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/self-closing-comp' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/sort-comp' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/sort-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/style-prop-object' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/void-dom-elements-no-children' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/annotations' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/ast' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/Components' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/defaultProps' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/docsUrl' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/error' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/getTokenBeforeClosingBracket' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/jsx' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/log' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/makeNoMethodSetStateRule' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/pragma' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/propTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/propWrapper' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/usedPropTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/variable' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/version' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-react/index' {
declare module.exports: $Exports<'eslint-plugin-react'>;
}
declare module 'eslint-plugin-react/index.js' {
declare module.exports: $Exports<'eslint-plugin-react'>;
}
declare module 'eslint-plugin-react/lib/rules/boolean-prop-naming.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/boolean-prop-naming'>;
}
declare module 'eslint-plugin-react/lib/rules/button-has-type.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/button-has-type'>;
}
declare module 'eslint-plugin-react/lib/rules/default-props-match-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/default-props-match-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/destructuring-assignment.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/destructuring-assignment'>;
}
declare module 'eslint-plugin-react/lib/rules/display-name.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/display-name'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-component-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-component-props'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-dom-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-dom-props'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-elements.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-elements'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-foreign-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-foreign-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-boolean-value.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-boolean-value'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-child-element-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-child-element-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-bracket-location.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-closing-bracket-location'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-tag-location.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-closing-tag-location'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-brace-presence.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-curly-brace-presence'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-curly-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-equals-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-equals-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-filename-extension.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-filename-extension'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-first-prop-new-line.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-first-prop-new-line'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-fragments.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-fragments'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-handler-names.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-handler-names'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-indent-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-indent'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-key.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-key'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-depth.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-max-depth'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-props-per-line.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-max-props-per-line'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-bind.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-bind'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-comment-textnodes.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-comment-textnodes'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-duplicate-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-duplicate-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-literals.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-literals'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-target-blank.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-target-blank'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-undef.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-undef'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-one-expression-per-line.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-one-expression-per-line'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-pascal-case.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-pascal-case'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-props-no-multi-spaces.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-props-no-multi-spaces'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-default-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-sort-default-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-sort-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-space-before-closing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-space-before-closing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-tag-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-tag-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-react.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-uses-react'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-vars.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-uses-vars'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-wrap-multilines.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-wrap-multilines'>;
}
declare module 'eslint-plugin-react/lib/rules/no-access-state-in-setstate.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-access-state-in-setstate'>;
}
declare module 'eslint-plugin-react/lib/rules/no-array-index-key.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-array-index-key'>;
}
declare module 'eslint-plugin-react/lib/rules/no-children-prop.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-children-prop'>;
}
declare module 'eslint-plugin-react/lib/rules/no-danger-with-children.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-danger-with-children'>;
}
declare module 'eslint-plugin-react/lib/rules/no-danger.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-danger'>;
}
declare module 'eslint-plugin-react/lib/rules/no-deprecated.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-deprecated'>;
}
declare module 'eslint-plugin-react/lib/rules/no-did-mount-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-did-mount-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-did-update-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-did-update-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-direct-mutation-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-direct-mutation-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-find-dom-node.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-find-dom-node'>;
}
declare module 'eslint-plugin-react/lib/rules/no-is-mounted.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-is-mounted'>;
}
declare module 'eslint-plugin-react/lib/rules/no-multi-comp.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-multi-comp'>;
}
declare module 'eslint-plugin-react/lib/rules/no-redundant-should-component-update.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-redundant-should-component-update'>;
}
declare module 'eslint-plugin-react/lib/rules/no-render-return-value.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-render-return-value'>;
}
declare module 'eslint-plugin-react/lib/rules/no-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-string-refs.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-string-refs'>;
}
declare module 'eslint-plugin-react/lib/rules/no-this-in-sfc.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-this-in-sfc'>;
}
declare module 'eslint-plugin-react/lib/rules/no-typos.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-typos'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unescaped-entities.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unescaped-entities'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unknown-property.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unknown-property'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unsafe.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unsafe'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unused-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unused-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-will-update-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-will-update-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/prefer-es6-class.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/prefer-es6-class'>;
}
declare module 'eslint-plugin-react/lib/rules/prefer-stateless-function.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/prefer-stateless-function'>;
}
declare module 'eslint-plugin-react/lib/rules/prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/react-in-jsx-scope.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/react-in-jsx-scope'>;
}
declare module 'eslint-plugin-react/lib/rules/require-default-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/require-default-props'>;
}
declare module 'eslint-plugin-react/lib/rules/require-optimization.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/require-optimization'>;
}
declare module 'eslint-plugin-react/lib/rules/require-render-return.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/require-render-return'>;
}
declare module 'eslint-plugin-react/lib/rules/self-closing-comp.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/self-closing-comp'>;
}
declare module 'eslint-plugin-react/lib/rules/sort-comp.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/sort-comp'>;
}
declare module 'eslint-plugin-react/lib/rules/sort-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/sort-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/style-prop-object.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/style-prop-object'>;
}
declare module 'eslint-plugin-react/lib/rules/void-dom-elements-no-children.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/void-dom-elements-no-children'>;
}
declare module 'eslint-plugin-react/lib/util/annotations.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/annotations'>;
}
declare module 'eslint-plugin-react/lib/util/ast.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/ast'>;
}
declare module 'eslint-plugin-react/lib/util/Components.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/Components'>;
}
declare module 'eslint-plugin-react/lib/util/defaultProps.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/defaultProps'>;
}
declare module 'eslint-plugin-react/lib/util/docsUrl.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/docsUrl'>;
}
declare module 'eslint-plugin-react/lib/util/error.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/error'>;
}
declare module 'eslint-plugin-react/lib/util/getTokenBeforeClosingBracket.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/getTokenBeforeClosingBracket'>;
}
declare module 'eslint-plugin-react/lib/util/jsx.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/jsx'>;
}
declare module 'eslint-plugin-react/lib/util/log.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/log'>;
}
declare module 'eslint-plugin-react/lib/util/makeNoMethodSetStateRule.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/makeNoMethodSetStateRule'>;
}
declare module 'eslint-plugin-react/lib/util/pragma.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/pragma'>;
}
declare module 'eslint-plugin-react/lib/util/props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/props'>;
}
declare module 'eslint-plugin-react/lib/util/propTypes.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/propTypes'>;
}
declare module 'eslint-plugin-react/lib/util/propWrapper.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/propWrapper'>;
}
declare module 'eslint-plugin-react/lib/util/usedPropTypes.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/usedPropTypes'>;
}
declare module 'eslint-plugin-react/lib/util/variable.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/variable'>;
}
declare module 'eslint-plugin-react/lib/util/version.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/version'>;
}

View file

@ -0,0 +1,59 @@
// flow-typed signature: 59893df9239e2d9724a90756a6525968
// flow-typed version: <<STUB>>/eslint-plugin-standard_v^4.0.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-standard'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-standard' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-standard/rules/array-bracket-even-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-standard/rules/computed-property-even-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-standard/rules/no-callback-literal' {
declare module.exports: any;
}
declare module 'eslint-plugin-standard/rules/object-curly-even-spacing' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-standard/index' {
declare module.exports: $Exports<'eslint-plugin-standard'>;
}
declare module 'eslint-plugin-standard/index.js' {
declare module.exports: $Exports<'eslint-plugin-standard'>;
}
declare module 'eslint-plugin-standard/rules/array-bracket-even-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/array-bracket-even-spacing'>;
}
declare module 'eslint-plugin-standard/rules/computed-property-even-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/computed-property-even-spacing'>;
}
declare module 'eslint-plugin-standard/rules/no-callback-literal.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/no-callback-literal'>;
}
declare module 'eslint-plugin-standard/rules/object-curly-even-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/object-curly-even-spacing'>;
}

2531
dist/flow-typed/npm/eslint_vx.x.x.js vendored Normal file

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,6 @@
// flow-typed signature: 6a5610678d4b01e13bbfbbc62bdaf583
// flow-typed version: 3817bc6980/flow-bin_v0.x.x/flow_>=v0.25.x
declare module "flow-bin" {
declare module.exports: string;
}

193
dist/flow-typed/npm/flow-typed_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,193 @@
// flow-typed signature: b46df6a09b982fc599f51cedf4d8ef6b
// flow-typed version: <<STUB>>/flow-typed_v^2.5.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'flow-typed'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'flow-typed' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'flow-typed/dist/cli' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/create-stub' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/install' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/runTests' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/search' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/update-cache' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/update' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/validateDefs' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/version' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/cacheRepoUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/codeSign' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/fileUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/flowProjectUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/flowVersion' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/git' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/github' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/isInFlowTypedRepo' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/libDefs' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/node' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/npm/npmLibDefs' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/npm/npmProjectUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/semver' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/stubUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/validationErrors' {
declare module.exports: any;
}
// Filename aliases
declare module 'flow-typed/dist/cli.js' {
declare module.exports: $Exports<'flow-typed/dist/cli'>;
}
declare module 'flow-typed/dist/commands/create-stub.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/create-stub'>;
}
declare module 'flow-typed/dist/commands/install.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/install'>;
}
declare module 'flow-typed/dist/commands/runTests.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/runTests'>;
}
declare module 'flow-typed/dist/commands/search.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/search'>;
}
declare module 'flow-typed/dist/commands/update-cache.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/update-cache'>;
}
declare module 'flow-typed/dist/commands/update.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/update'>;
}
declare module 'flow-typed/dist/commands/validateDefs.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/validateDefs'>;
}
declare module 'flow-typed/dist/commands/version.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/version'>;
}
declare module 'flow-typed/dist/lib/cacheRepoUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/cacheRepoUtils'>;
}
declare module 'flow-typed/dist/lib/codeSign.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/codeSign'>;
}
declare module 'flow-typed/dist/lib/fileUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/fileUtils'>;
}
declare module 'flow-typed/dist/lib/flowProjectUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/flowProjectUtils'>;
}
declare module 'flow-typed/dist/lib/flowVersion.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/flowVersion'>;
}
declare module 'flow-typed/dist/lib/git.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/git'>;
}
declare module 'flow-typed/dist/lib/github.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/github'>;
}
declare module 'flow-typed/dist/lib/isInFlowTypedRepo.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/isInFlowTypedRepo'>;
}
declare module 'flow-typed/dist/lib/libDefs.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/libDefs'>;
}
declare module 'flow-typed/dist/lib/node.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/node'>;
}
declare module 'flow-typed/dist/lib/npm/npmLibDefs.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/npm/npmLibDefs'>;
}
declare module 'flow-typed/dist/lib/npm/npmProjectUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/npm/npmProjectUtils'>;
}
declare module 'flow-typed/dist/lib/semver.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/semver'>;
}
declare module 'flow-typed/dist/lib/stubUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/stubUtils'>;
}
declare module 'flow-typed/dist/lib/validationErrors.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/validationErrors'>;
}

88
dist/flow-typed/npm/husky_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,88 @@
// flow-typed signature: 09dc7be6f5dfade9410350e5f356b1e6
// flow-typed version: <<STUB>>/husky_v^0.14.3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'husky'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'husky' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'husky/__tests__/index' {
declare module.exports: any;
}
declare module 'husky/bin/install' {
declare module.exports: any;
}
declare module 'husky/bin/uninstall' {
declare module.exports: any;
}
declare module 'husky/src/install' {
declare module.exports: any;
}
declare module 'husky/src/uninstall' {
declare module.exports: any;
}
declare module 'husky/src/utils/find-hooks-dir' {
declare module.exports: any;
}
declare module 'husky/src/utils/find-parent' {
declare module.exports: any;
}
declare module 'husky/src/utils/get-hook-script' {
declare module.exports: any;
}
declare module 'husky/src/utils/is-husky' {
declare module.exports: any;
}
// Filename aliases
declare module 'husky/__tests__/index.js' {
declare module.exports: $Exports<'husky/__tests__/index'>;
}
declare module 'husky/bin/install.js' {
declare module.exports: $Exports<'husky/bin/install'>;
}
declare module 'husky/bin/uninstall.js' {
declare module.exports: $Exports<'husky/bin/uninstall'>;
}
declare module 'husky/src/install.js' {
declare module.exports: $Exports<'husky/src/install'>;
}
declare module 'husky/src/uninstall.js' {
declare module.exports: $Exports<'husky/src/uninstall'>;
}
declare module 'husky/src/utils/find-hooks-dir.js' {
declare module.exports: $Exports<'husky/src/utils/find-hooks-dir'>;
}
declare module 'husky/src/utils/find-parent.js' {
declare module.exports: $Exports<'husky/src/utils/find-parent'>;
}
declare module 'husky/src/utils/get-hook-script.js' {
declare module.exports: $Exports<'husky/src/utils/get-hook-script'>;
}
declare module 'husky/src/utils/is-husky.js' {
declare module.exports: $Exports<'husky/src/utils/is-husky'>;
}

View file

@ -0,0 +1,108 @@
// flow-typed signature: 1b9179cadf091d93c5142d3673b2e210
// flow-typed version: <<STUB>>/lint-staged_v^7.0.4/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'lint-staged'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'lint-staged' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'lint-staged/src/calcChunkSize' {
declare module.exports: any;
}
declare module 'lint-staged/src/checkPkgScripts' {
declare module.exports: any;
}
declare module 'lint-staged/src/findBin' {
declare module.exports: any;
}
declare module 'lint-staged/src/generateTasks' {
declare module.exports: any;
}
declare module 'lint-staged/src/getConfig' {
declare module.exports: any;
}
declare module 'lint-staged/src/index' {
declare module.exports: any;
}
declare module 'lint-staged/src/makeCmdTasks' {
declare module.exports: any;
}
declare module 'lint-staged/src/printErrors' {
declare module.exports: any;
}
declare module 'lint-staged/src/resolveGitDir' {
declare module.exports: any;
}
declare module 'lint-staged/src/resolveTaskFn' {
declare module.exports: any;
}
declare module 'lint-staged/src/runAll' {
declare module.exports: any;
}
// Filename aliases
declare module 'lint-staged/index' {
declare module.exports: $Exports<'lint-staged'>;
}
declare module 'lint-staged/index.js' {
declare module.exports: $Exports<'lint-staged'>;
}
declare module 'lint-staged/src/calcChunkSize.js' {
declare module.exports: $Exports<'lint-staged/src/calcChunkSize'>;
}
declare module 'lint-staged/src/checkPkgScripts.js' {
declare module.exports: $Exports<'lint-staged/src/checkPkgScripts'>;
}
declare module 'lint-staged/src/findBin.js' {
declare module.exports: $Exports<'lint-staged/src/findBin'>;
}
declare module 'lint-staged/src/generateTasks.js' {
declare module.exports: $Exports<'lint-staged/src/generateTasks'>;
}
declare module 'lint-staged/src/getConfig.js' {
declare module.exports: $Exports<'lint-staged/src/getConfig'>;
}
declare module 'lint-staged/src/index.js' {
declare module.exports: $Exports<'lint-staged/src/index'>;
}
declare module 'lint-staged/src/makeCmdTasks.js' {
declare module.exports: $Exports<'lint-staged/src/makeCmdTasks'>;
}
declare module 'lint-staged/src/printErrors.js' {
declare module.exports: $Exports<'lint-staged/src/printErrors'>;
}
declare module 'lint-staged/src/resolveGitDir.js' {
declare module.exports: $Exports<'lint-staged/src/resolveGitDir'>;
}
declare module 'lint-staged/src/resolveTaskFn.js' {
declare module.exports: $Exports<'lint-staged/src/resolveTaskFn'>;
}
declare module 'lint-staged/src/runAll.js' {
declare module.exports: $Exports<'lint-staged/src/runAll'>;
}

178
dist/flow-typed/npm/prettier_v1.x.x.js vendored Normal file
View file

@ -0,0 +1,178 @@
// flow-typed signature: 066c92e9ccb5f0711df8d73cbca837d6
// flow-typed version: 9e32affdbd/prettier_v1.x.x/flow_>=v0.56.x
declare module "prettier" {
declare export type AST = Object;
declare export type Doc = Object;
declare export type FastPath = Object;
declare export type PrettierParserName =
| "babylon"
| "flow"
| "typescript"
| "postcss"
| "css"
| "less"
| "scss"
| "json"
| "graphql"
| "markdown"
| "vue";
declare export type PrettierParser = {
[name: PrettierParserName]: (text: string, options?: Object) => AST
};
declare export type CustomParser = (
text: string,
parsers: PrettierParser,
options: Options
) => AST;
declare export type Options = {|
printWidth?: number,
tabWidth?: number,
useTabs?: boolean,
semi?: boolean,
singleQuote?: boolean,
trailingComma?: "none" | "es5" | "all",
bracketSpacing?: boolean,
jsxBracketSameLine?: boolean,
arrowParens?: "avoid" | "always",
rangeStart?: number,
rangeEnd?: number,
parser?: PrettierParserName | CustomParser,
filepath?: string,
requirePragma?: boolean,
insertPragma?: boolean,
proseWrap?: "always" | "never" | "preserve",
plugins?: Array<string | Plugin>
|};
declare export type Plugin = {
languages: SupportLanguage,
parsers: { [parserName: string]: Parser },
printers: { [astFormat: string]: Printer }
};
declare export type Parser = {
parse: (
text: string,
parsers: { [parserName: string]: Parser },
options: Object
) => AST,
astFormat: string
};
declare export type Printer = {
print: (
path: FastPath,
options: Object,
print: (path: FastPath) => Doc
) => Doc,
embed: (
path: FastPath,
print: (path: FastPath) => Doc,
textToDoc: (text: string, options: Object) => Doc,
options: Object
) => ?Doc
};
declare export type CursorOptions = {|
cursorOffset: number,
printWidth?: $PropertyType<Options, "printWidth">,
tabWidth?: $PropertyType<Options, "tabWidth">,
useTabs?: $PropertyType<Options, "useTabs">,
semi?: $PropertyType<Options, "semi">,
singleQuote?: $PropertyType<Options, "singleQuote">,
trailingComma?: $PropertyType<Options, "trailingComma">,
bracketSpacing?: $PropertyType<Options, "bracketSpacing">,
jsxBracketSameLine?: $PropertyType<Options, "jsxBracketSameLine">,
arrowParens?: $PropertyType<Options, "arrowParens">,
parser?: $PropertyType<Options, "parser">,
filepath?: $PropertyType<Options, "filepath">,
requirePragma?: $PropertyType<Options, "requirePragma">,
insertPragma?: $PropertyType<Options, "insertPragma">,
proseWrap?: $PropertyType<Options, "proseWrap">,
plugins?: $PropertyType<Options, "plugins">
|};
declare export type CursorResult = {|
formatted: string,
cursorOffset: number
|};
declare export type ResolveConfigOptions = {|
useCache?: boolean,
config?: string,
editorconfig?: boolean
|};
declare export type SupportLanguage = {
name: string,
since: string,
parsers: Array<string>,
group?: string,
tmScope: string,
aceMode: string,
codemirrorMode: string,
codemirrorMimeType: string,
aliases?: Array<string>,
extensions: Array<string>,
filenames?: Array<string>,
linguistLanguageId: number,
vscodeLanguageIds: Array<string>
};
declare export type SupportOption = {|
since: string,
type: "int" | "boolean" | "choice" | "path",
deprecated?: string,
redirect?: SupportOptionRedirect,
description: string,
oppositeDescription?: string,
default: SupportOptionValue,
range?: SupportOptionRange,
choices?: SupportOptionChoice
|};
declare export type SupportOptionRedirect = {|
options: string,
value: SupportOptionValue
|};
declare export type SupportOptionRange = {|
start: number,
end: number,
step: number
|};
declare export type SupportOptionChoice = {|
value: boolean | string,
description?: string,
since?: string,
deprecated?: string,
redirect?: SupportOptionValue
|};
declare export type SupportOptionValue = number | boolean | string;
declare export type SupportInfo = {|
languages: Array<SupportLanguage>,
options: Array<SupportOption>
|};
declare export type Prettier = {|
format: (source: string, options?: Options) => string,
check: (source: string, options?: Options) => boolean,
formatWithCursor: (source: string, options: CursorOptions) => CursorResult,
resolveConfig: {
(filePath: string, options?: ResolveConfigOptions): Promise<?Options>,
sync(filePath: string, options?: ResolveConfigOptions): ?Options
},
clearConfigCache: () => void,
getSupportInfo: (version?: string) => SupportInfo
|};
declare export default Prettier;
}

View file

@ -0,0 +1,46 @@
// flow-typed signature: 85f3cee3ef579fc4277423833cd8f304
// flow-typed version: <<STUB>>/proxy-polyfill_v0.1.6/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'proxy-polyfill'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'proxy-polyfill' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'proxy-polyfill/proxy' {
declare module.exports: any;
}
declare module 'proxy-polyfill/proxy.min' {
declare module.exports: any;
}
declare module 'proxy-polyfill/suite' {
declare module.exports: any;
}
// Filename aliases
declare module 'proxy-polyfill/proxy.js' {
declare module.exports: $Exports<'proxy-polyfill/proxy'>;
}
declare module 'proxy-polyfill/proxy.min.js' {
declare module.exports: $Exports<'proxy-polyfill/proxy.min'>;
}
declare module 'proxy-polyfill/suite.js' {
declare module.exports: $Exports<'proxy-polyfill/suite'>;
}

View file

@ -0,0 +1,74 @@
// flow-typed signature: f394c50a048b5a7ebd278b90412df2ed
// flow-typed version: <<STUB>>/rollup-plugin-babel_v3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-babel'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-babel' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.cjs' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.es' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/constants' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/helperPlugin' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/index' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/preflightCheck' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/utils' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.cjs.js' {
declare module.exports: $Exports<'rollup-plugin-babel/dist/rollup-plugin-babel.cjs'>;
}
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.es.js' {
declare module.exports: $Exports<'rollup-plugin-babel/dist/rollup-plugin-babel.es'>;
}
declare module 'rollup-plugin-babel/src/constants.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/constants'>;
}
declare module 'rollup-plugin-babel/src/helperPlugin.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/helperPlugin'>;
}
declare module 'rollup-plugin-babel/src/index.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/index'>;
}
declare module 'rollup-plugin-babel/src/preflightCheck.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/preflightCheck'>;
}
declare module 'rollup-plugin-babel/src/utils.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/utils'>;
}

View file

@ -0,0 +1,39 @@
// flow-typed signature: 0b11a12fd929a3a3afd136d42a652bd9
// flow-typed version: <<STUB>>/rollup-plugin-copy_v^1.1.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-copy'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-copy' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup-plugin-copy/dist/index.commonjs' {
declare module.exports: any;
}
declare module 'rollup-plugin-copy/dist/index.module' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup-plugin-copy/dist/index.commonjs.js' {
declare module.exports: $Exports<'rollup-plugin-copy/dist/index.commonjs'>;
}
declare module 'rollup-plugin-copy/dist/index.module.js' {
declare module.exports: $Exports<'rollup-plugin-copy/dist/index.module'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: 57ac4a4687dd0b10d420e17d2d30e534
// flow-typed version: <<STUB>>/rollup-plugin-eslint_v^5.1.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-eslint'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-eslint' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'rollup-plugin-eslint/index' {
declare module.exports: $Exports<'rollup-plugin-eslint'>;
}
declare module 'rollup-plugin-eslint/index.js' {
declare module.exports: $Exports<'rollup-plugin-eslint'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: 25586f0fba8b577d1a0f5bd6b4167dae
// flow-typed version: <<STUB>>/rollup-plugin-flow_v^1.1.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-flow'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-flow' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'rollup-plugin-flow/index' {
declare module.exports: $Exports<'rollup-plugin-flow'>;
}
declare module 'rollup-plugin-flow/index.js' {
declare module.exports: $Exports<'rollup-plugin-flow'>;
}

View file

@ -0,0 +1,39 @@
// flow-typed signature: a36cd847454eb7e3f098cadbd0745e0a
// flow-typed version: <<STUB>>/rollup-plugin-includepaths_v^0.2.3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-includepaths'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-includepaths' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup-plugin-includepaths/src/plugin.es5' {
declare module.exports: any;
}
declare module 'rollup-plugin-includepaths/src/plugin' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup-plugin-includepaths/src/plugin.es5.js' {
declare module.exports: $Exports<'rollup-plugin-includepaths/src/plugin.es5'>;
}
declare module 'rollup-plugin-includepaths/src/plugin.js' {
declare module.exports: $Exports<'rollup-plugin-includepaths/src/plugin'>;
}

53
dist/flow-typed/npm/rollup_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,53 @@
// flow-typed signature: e8ee84a58128c679bea1b5976f7f00cf
// flow-typed version: <<STUB>>/rollup_v^1.8.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup/dist/rollup.browser.es' {
declare module.exports: any;
}
declare module 'rollup/dist/rollup.browser' {
declare module.exports: any;
}
declare module 'rollup/dist/rollup.es' {
declare module.exports: any;
}
declare module 'rollup/dist/rollup' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup/dist/rollup.browser.es.js' {
declare module.exports: $Exports<'rollup/dist/rollup.browser.es'>;
}
declare module 'rollup/dist/rollup.browser.js' {
declare module.exports: $Exports<'rollup/dist/rollup.browser'>;
}
declare module 'rollup/dist/rollup.es.js' {
declare module.exports: $Exports<'rollup/dist/rollup.es'>;
}
declare module 'rollup/dist/rollup.js' {
declare module.exports: $Exports<'rollup/dist/rollup'>;
}

102
dist/flow-typed/npm/uuid_v3.x.x.js vendored Normal file
View file

@ -0,0 +1,102 @@
// flow-typed signature: 3cf668e64747095cab0bb360cf2fb34f
// flow-typed version: d659bd0cb8/uuid_v3.x.x/flow_>=v0.32.x
declare module "uuid" {
declare class uuid {
static (
options?: {|
random?: number[],
rng?: () => number[] | Buffer
|},
buffer?: number[] | Buffer,
offset?: number
): string,
static v1(
options?: {|
node?: number[],
clockseq?: number,
msecs?: number | Date,
nsecs?: number
|},
buffer?: number[] | Buffer,
offset?: number
): string,
static v4(
options?: {|
random?: number[],
rng?: () => number[] | Buffer
|},
buffer?: number[] | Buffer,
offset?: number
): string
}
declare module.exports: Class<uuid>;
}
declare module "uuid/v1" {
declare class v1 {
static (
options?: {|
node?: number[],
clockseq?: number,
msecs?: number | Date,
nsecs?: number
|},
buffer?: number[] | Buffer,
offset?: number
): string
}
declare module.exports: Class<v1>;
}
declare module "uuid/v3" {
declare class v3 {
static (
name?: string | number[],
namespace?: string | number[],
buffer?: number[] | Buffer,
offset?: number
): string,
static name: string,
static DNS: string,
static URL: string
}
declare module.exports: Class<v3>;
}
declare module "uuid/v4" {
declare class v4 {
static (
options?: {|
random?: number[],
rng?: () => number[] | Buffer
|},
buffer?: number[] | Buffer,
offset?: number
): string
}
declare module.exports: Class<v4>;
}
declare module "uuid/v5" {
declare class v5 {
static (
name?: string | number[],
namespace?: string | number[],
buffer?: number[] | Buffer,
offset?: number
): string,
static name: string,
static DNS: string,
static URL: string
}
declare module.exports: Class<v5>;
}

6
dist/flow-typed/reselect.js vendored Normal file
View file

@ -0,0 +1,6 @@
// @flow
// We should be using the `reselect` that comes with flow-typed but it's going to take a ton of work to get that working
// without any errors. For now it's any type
declare module 'reselect' {
declare module.exports: any;
}

113
flow-typed/Claim.js vendored Normal file
View file

@ -0,0 +1,113 @@
// @flow
declare type ClaimWithPossibleCertificate = {
certificate?: ChannelClaim,
claim: StreamClaim,
};
declare type ChannelClaim = GenericClaim & {
value: ChannelMetadata,
};
declare type StreamClaim = GenericClaim & {
is_channel_signature_valid?: boolean,
signing_channel?: {
claim_id: string,
name: string,
value: {
public_key: string,
},
},
value: StreamMetadata,
};
declare type GenericClaim = {
address: string, // address associated with tx
amount: number, // bid amount at time of tx
claim_id: string, // unique claim identifier
claim_sequence: number,
claim_op: 'create' | 'update',
confirmations: number, // This isn't the most stable atm: https://github.com/lbryio/lbry/issues/2000
decoded_claim: boolean, // claim made in accordance with sdk protobuf types
depth: number, // confirmations since tx
effective_amount: number, // bid amount + supports
has_signature: boolean,
height: number, // block height the tx was confirmed
hex: string, // `value` hex encoded
name: string,
channel_name?: string,
normalized_name: string, // `name` normalized via unicode NFD spec,
nout: number, // index number for an output of a tx
permanent_url: string, // name + claim_id
supports: Array<{}>, // TODO: add support type once we start using it
txid: string, // unique tx id
type: 'claim' | 'update' | 'support',
valid_at_height?: number, // BUG: this should always exist https://github.com/lbryio/lbry/issues/1728
value_type: 'stream' | 'channel',
};
declare type GenericMetadata = {
title?: string,
description?: string,
thumbnail?: {
url?: string,
},
languages?: Array<string>,
tags?: Array<string>,
locations?: Array<Location>,
};
declare type ChannelMetadata = GenericMetadata & {
public_key: string,
cover_url?: string,
contact_email?: string,
homepage_url?: string,
};
declare type StreamMetadata = GenericMetadata & {
license?: string, // License "title" ex: Creative Commons, Custom copyright
license_url?: string, // Link to full license
release_time?: number, // linux timestamp
author?: string,
source: {
sd_hash: string,
media_type?: string,
hash?: string,
name?: string, // file name
size?: number, // size of file in bytes
},
// Only exists if a stream has a fee
fee?: {
amount: number, // should be a string https://github.com/lbryio/lbry/issues/1576
currency: string,
address: string,
},
stream_type: 'video' | 'audio' | 'image' | 'software',
// Below correspond to `stream_type`
video?: {
duration: number,
height: number,
width: number,
},
audio?: {
duration: number,
},
image?: {
height: number,
width: number,
},
software?: {
os: string,
},
};
declare type Location = {
latitude?: number,
longitude?: number,
country?: string,
state?: string,
code?: string,
};

35
flow-typed/File.js vendored Normal file
View file

@ -0,0 +1,35 @@
// @flow
declare type FileListItem = {
metadata: StreamMetadata,
blobs_completed: number,
blobs_in_stream: number,
blobs_remaining: number,
channel_claim_id: string,
channel_name: string,
claim_id: string,
claim_name: string,
completed: false,
download_directory: string,
download_path: string,
file_name: string,
key: string,
mime_type: string,
nout: number,
outpoint: string,
points_paid: number,
protobuf: string,
sd_hash: string,
status: string,
stopped: false,
stream_hash: string,
stream_name: string,
suggested_file_name: string,
total_bytes: number,
total_bytes_lower_bound: number,
// TODO: sdk plans to change `tx`
// It isn't currently used by the apps
tx: {},
txid: string,
written_bytes: number,
};

175
flow-typed/Lbry.js vendored Normal file
View file

@ -0,0 +1,175 @@
// @flow
declare type StatusResponse = {
blob_manager: {
finished_blobs: number,
},
blockchain_headers: {
download_progress: number,
downloading_headers: boolean,
},
connection_status: {
code: string,
message: string,
},
dht: {
node_id: string,
peers_in_routing_table: number,
},
hash_announcer: {
announce_queue_size: number,
},
installation_id: string,
is_running: boolean,
skipped_components: Array<string>,
startup_status: {
blob_manager: boolean,
blockchain_headers: boolean,
database: boolean,
dht: boolean,
exchange_rate_manager: boolean,
hash_announcer: boolean,
peer_protocol_server: boolean,
stream_manager: boolean,
upnp: boolean,
wallet: boolean,
},
stream_manager: {
managed_files: number,
},
upnp: {
aioupnp_version: string,
dht_redirect_set: boolean,
external_ip: string,
gateway: string,
peer_redirect_set: boolean,
redirects: {},
},
wallet: ?{
best_blockhash: string,
blocks: number,
blocks_behind: number,
is_encrypted: boolean,
is_locked: boolean,
},
};
declare type VersionResponse = {
build: string,
lbrynet_version: string,
os_release: string,
os_system: string,
platform: string,
processor: string,
python_version: string,
};
declare type ResolveResponse = {
// Keys are the url(s) passed to resolve
[string]:
| { error: {}, certificate: ChannelClaim, claims_in_channel: number }
| { error?: {}, claim: StreamClaim, certificate?: ChannelClaim },
};
declare type GetResponse = FileListItem;
declare type GenericTxResponse = {
height: number,
hex: string,
inputs: Array<{}>,
outputs: Array<{}>,
total_fee: string,
total_input: string,
total_output: string,
txid: string,
};
declare type PublishResponse = GenericTxResponse & {
// Only first value in outputs is a claim
// That's the only value we care about
outputs: Array<StreamClaim>,
};
declare type ClaimSearchResponse = {
items: Array<StreamClaim>,
page: number,
page_size: number,
page_number: number,
};
declare type ClaimListResponse = {
claims: Array<ChannelClaim | StreamClaim>,
};
declare type ChannelCreateResponse = GenericTxResponse & {
outputs: Array<ChannelClaim>,
};
declare type ChannelListResponse = Array<ChannelClaim>;
declare type FileListResponse = Array<FileListItem>;
declare type TxListResponse = Array<Transaction>;
declare type BlobListResponse = Array<string>;
declare type AccountListResponse = Array<{
id: string,
is_default: string,
ledger: string,
name: string,
seed: string,
encrypted: string,
private_key: string,
public_key: string,
address_generator: string,
modified_on: string,
}>;
//
// Types used in the generic Lbry object that is exported
//
declare type LbryTypes = {
isConnected: boolean,
connectPromise: ?Promise<any>,
connect: () => void,
daemonConnectionString: string,
setDaemonConnectionString: string => void,
overrides: { [string]: ?Function },
setOverride: (string, Function) => void,
getMediaType: (string, ?string) => string,
// Lbry Methods
stop: () => Promise<string>,
status: () => Promise<StatusResponse>,
version: () => Promise<VersionResponse>,
resolve: (params: {}) => Promise<ResolveResponse>,
get: (params: {}) => Promise<GetResponse>,
publish: (params: {}) => Promise<PublishResponse>,
claim_search: (params: {}) => Promise<ClaimSearchResponse>,
claim_list: (params?: {}) => Promise<ClaimListResponse>,
channel_create: (params: {}) => Promise<ChannelCreateResponse>,
channel_list: () => Promise<ChannelListResponse>,
stream_abandon: (params: {}) => Promise<GenericTxResponse>,
channel_abandon: (params: {}) => Promise<GenericTxResponse>,
support_create: (params: {}) => Promise<GenericTxResponse>,
// File fetching and manipulation
file_list: (params: {}) => Promise<FileListResponse>,
file_delete: (params: {}) => Promise<boolean>,
blob_delete: (params: {}) => Promise<string>,
blob_list: (params: {}) => Promise<BlobListResponse>,
// Wallet utilities
account_balance: (params: {}) => Promise<string>,
account_decrypt: (prams: {}) => Promise<boolean>,
account_encrypt: (params: {}) => Promise<boolean>,
account_unlock: (params: {}) => Promise<boolean>,
account_list: (params: {}) => Promise<AccountListResponse>,
account_send: (params: {}) => Promise<GenericTxResponse>,
address_is_mine: (params: {}) => Promise<boolean>,
address_unused: (params: {}) => Promise<string>, // New address
transaction_list: (params: {}) => Promise<TxListResponse>,
// The app shouldn't need to do this
utxo_release: () => Promise<any>,
};

93
flow-typed/Notification.js vendored Normal file
View file

@ -0,0 +1,93 @@
// @flow
import * as ACTIONS from 'constants/action_types';
/*
Toasts:
- First-in, first-out queue
- Simple messages that are shown in response to user interactions
- Never saved
- If they are the result of errors, use the isError flag when creating
- For errors that should interrupt user behavior, use Error
*/
declare type ToastParams = {
message: string,
title?: string,
linkText?: string,
linkTarget?: string,
isError?: boolean,
};
declare type Toast = {
id: string,
params: ToastParams,
};
declare type DoToast = {
type: ACTIONS.CREATE_TOAST,
data: Toast,
};
/*
Notifications:
- List of notifications based on user interactions/app notifications
- Always saved, but can be manually deleted
- Can happen in the background, or because of user interaction (ex: publish confirmed)
*/
declare type Notification = {
id: string, // Unique id
dateCreated: number,
isRead: boolean, // Used to display "new" notifications that a user hasn't seen yet
source?: string, // The type/area an notification is from. Used for sorting (ex: publishes, transactions)
// We may want to use priority/isDismissed in the future to specify how urgent a notification is
// and if the user should see it immediately
// isDissmied: boolean,
// priority?: number
};
declare type DoNotification = {
type: ACTIONS.CREATE_NOTIFICATION,
data: Notification,
};
declare type DoEditNotification = {
type: ACTIONS.EDIT_NOTIFICATION,
data: {
notification: Notification,
},
};
declare type DoDeleteNotification = {
type: ACTIONS.DELETE_NOTIFICATION,
data: {
id: string, // The id to delete
},
};
/*
Errors:
- First-in, first-out queue
- Errors that should interupt user behavior
- For errors that can be shown without interrupting a user, use Toast with the isError flag
*/
declare type ErrorNotification = {
title: string,
text: string,
};
declare type DoError = {
type: ACTIONS.CREATE_ERROR,
data: ErrorNotification,
};
declare type DoDismissError = {
type: ACTIONS.DISMISS_ERROR,
};
/*
NotificationState
*/
declare type NotificationState = {
notifications: Array<Notification>,
errors: Array<ErrorNotification>,
toasts: Array<Toast>,
};

6
flow-typed/Redux.js vendored Normal file
View file

@ -0,0 +1,6 @@
// @flow
/* eslint-disable no-use-before-define */
declare type GetState = () => any;
declare type ThunkAction = (dispatch: Dispatch, getState: GetState) => any;
declare type Dispatch = (action: {} | Promise<*> | Array<{}> | ThunkAction) => any; // Need to refer to ThunkAction
/* eslint-enable */

59
flow-typed/Search.js vendored Normal file
View file

@ -0,0 +1,59 @@
// @flow
import * as ACTIONS from 'constants/action_types';
declare type SearchSuggestion = {
value: string,
shorthand: string,
type: string,
};
declare type SearchOptions = {
// :(
// https://github.com/facebook/flow/issues/6492
RESULT_COUNT: number,
CLAIM_TYPE: string,
INCLUDE_FILES: string,
INCLUDE_CHANNELS: string,
INCLUDE_FILES_AND_CHANNELS: string,
MEDIA_AUDIO: string,
MEDIA_VIDEO: string,
MEDIA_TEXT: string,
MEDIA_IMAGE: string,
MEDIA_APPLICATION: string,
};
declare type SearchState = {
isActive: boolean,
searchQuery: string,
options: SearchOptions,
suggestions: { [string]: Array<SearchSuggestion> },
urisByQuery: {},
};
declare type SearchSuccess = {
type: ACTIONS.SEARCH_SUCCESS,
data: {
query: string,
uris: Array<string>,
},
};
declare type UpdateSearchQuery = {
type: ACTIONS.UPDATE_SEARCH_QUERY,
data: {
query: string,
},
};
declare type UpdateSearchSuggestions = {
type: ACTIONS.UPDATE_SEARCH_SUGGESTIONS,
data: {
query: string,
suggestions: Array<SearchSuggestion>,
},
};
declare type UpdateSearchOptions = {
type: ACTIONS.UPDATE_SEARCH_OPTIONS,
data: SearchOptions,
};

11
flow-typed/Transaction.js vendored Normal file
View file

@ -0,0 +1,11 @@
// @flow
declare type Transaction = {
amount: number,
claim_id: string,
claim_name: string,
fee: number,
nout: number,
txid: string,
type: string,
date: Date,
};

234
flow-typed/npm/babel-core_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,234 @@
// flow-typed signature: 0f3ee620f0bd9a317baba1570b7f9328
// flow-typed version: <<STUB>>/babel-core_v^6.26.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-core'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-core' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-core/lib/api/browser' {
declare module.exports: any;
}
declare module 'babel-core/lib/api/node' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/get-possible-plugin-names' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/get-possible-preset-names' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/merge' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/normalize-ast' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve-from-possible-names' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve-plugin' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve-preset' {
declare module.exports: any;
}
declare module 'babel-core/lib/helpers/resolve' {
declare module.exports: any;
}
declare module 'babel-core/lib/store' {
declare module.exports: any;
}
declare module 'babel-core/lib/tools/build-external-helpers' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/index' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/logger' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/merge-map' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/metadata' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/build-config-chain' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/config' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/index' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/option-manager' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/parsers' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/file/options/removed' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/internal-plugins/block-hoist' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/internal-plugins/shadow-functions' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/pipeline' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/plugin-pass' {
declare module.exports: any;
}
declare module 'babel-core/lib/transformation/plugin' {
declare module.exports: any;
}
declare module 'babel-core/lib/util' {
declare module.exports: any;
}
declare module 'babel-core/register' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-core/index' {
declare module.exports: $Exports<'babel-core'>;
}
declare module 'babel-core/index.js' {
declare module.exports: $Exports<'babel-core'>;
}
declare module 'babel-core/lib/api/browser.js' {
declare module.exports: $Exports<'babel-core/lib/api/browser'>;
}
declare module 'babel-core/lib/api/node.js' {
declare module.exports: $Exports<'babel-core/lib/api/node'>;
}
declare module 'babel-core/lib/helpers/get-possible-plugin-names.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/get-possible-plugin-names'>;
}
declare module 'babel-core/lib/helpers/get-possible-preset-names.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/get-possible-preset-names'>;
}
declare module 'babel-core/lib/helpers/merge.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/merge'>;
}
declare module 'babel-core/lib/helpers/normalize-ast.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/normalize-ast'>;
}
declare module 'babel-core/lib/helpers/resolve-from-possible-names.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve-from-possible-names'>;
}
declare module 'babel-core/lib/helpers/resolve-plugin.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve-plugin'>;
}
declare module 'babel-core/lib/helpers/resolve-preset.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve-preset'>;
}
declare module 'babel-core/lib/helpers/resolve.js' {
declare module.exports: $Exports<'babel-core/lib/helpers/resolve'>;
}
declare module 'babel-core/lib/store.js' {
declare module.exports: $Exports<'babel-core/lib/store'>;
}
declare module 'babel-core/lib/tools/build-external-helpers.js' {
declare module.exports: $Exports<'babel-core/lib/tools/build-external-helpers'>;
}
declare module 'babel-core/lib/transformation/file/index.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/index'>;
}
declare module 'babel-core/lib/transformation/file/logger.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/logger'>;
}
declare module 'babel-core/lib/transformation/file/merge-map.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/merge-map'>;
}
declare module 'babel-core/lib/transformation/file/metadata.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/metadata'>;
}
declare module 'babel-core/lib/transformation/file/options/build-config-chain.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/build-config-chain'>;
}
declare module 'babel-core/lib/transformation/file/options/config.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/config'>;
}
declare module 'babel-core/lib/transformation/file/options/index.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/index'>;
}
declare module 'babel-core/lib/transformation/file/options/option-manager.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/option-manager'>;
}
declare module 'babel-core/lib/transformation/file/options/parsers.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/parsers'>;
}
declare module 'babel-core/lib/transformation/file/options/removed.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/file/options/removed'>;
}
declare module 'babel-core/lib/transformation/internal-plugins/block-hoist.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/internal-plugins/block-hoist'>;
}
declare module 'babel-core/lib/transformation/internal-plugins/shadow-functions.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/internal-plugins/shadow-functions'>;
}
declare module 'babel-core/lib/transformation/pipeline.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/pipeline'>;
}
declare module 'babel-core/lib/transformation/plugin-pass.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/plugin-pass'>;
}
declare module 'babel-core/lib/transformation/plugin.js' {
declare module.exports: $Exports<'babel-core/lib/transformation/plugin'>;
}
declare module 'babel-core/lib/util.js' {
declare module.exports: $Exports<'babel-core/lib/util'>;
}
declare module 'babel-core/register.js' {
declare module.exports: $Exports<'babel-core/register'>;
}

123
flow-typed/npm/babel-eslint_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,123 @@
// flow-typed signature: bc167658b3892d915f873ecc31946cba
// flow-typed version: <<STUB>>/babel-eslint_v^8.0.3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-eslint'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-eslint' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-eslint/lib/analyze-scope' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/attachComments' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertComments' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertTemplateType' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/index' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/toAST' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/toToken' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/babylon-to-espree/toTokens' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/index' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/parse-with-patch' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/parse-with-scope' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/parse' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/patch-eslint-scope' {
declare module.exports: any;
}
declare module 'babel-eslint/lib/visitor-keys' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-eslint/lib/analyze-scope.js' {
declare module.exports: $Exports<'babel-eslint/lib/analyze-scope'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/attachComments.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/attachComments'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertComments.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/convertComments'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/convertTemplateType.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/convertTemplateType'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/index.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/index'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/toAST.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/toAST'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/toToken.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/toToken'>;
}
declare module 'babel-eslint/lib/babylon-to-espree/toTokens.js' {
declare module.exports: $Exports<'babel-eslint/lib/babylon-to-espree/toTokens'>;
}
declare module 'babel-eslint/lib/index.js' {
declare module.exports: $Exports<'babel-eslint/lib/index'>;
}
declare module 'babel-eslint/lib/parse-with-patch.js' {
declare module.exports: $Exports<'babel-eslint/lib/parse-with-patch'>;
}
declare module 'babel-eslint/lib/parse-with-scope.js' {
declare module.exports: $Exports<'babel-eslint/lib/parse-with-scope'>;
}
declare module 'babel-eslint/lib/parse.js' {
declare module.exports: $Exports<'babel-eslint/lib/parse'>;
}
declare module 'babel-eslint/lib/patch-eslint-scope.js' {
declare module.exports: $Exports<'babel-eslint/lib/patch-eslint-scope'>;
}
declare module 'babel-eslint/lib/visitor-keys.js' {
declare module.exports: $Exports<'babel-eslint/lib/visitor-keys'>;
}

67
flow-typed/npm/babel-loader_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,67 @@
// flow-typed signature: ac35c8b7c7b43815c9bfe7048b1f036b
// flow-typed version: <<STUB>>/babel-loader_v^7.1.4/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-loader'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-loader' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-loader/lib/fs-cache' {
declare module.exports: any;
}
declare module 'babel-loader/lib/index' {
declare module.exports: any;
}
declare module 'babel-loader/lib/resolve-rc' {
declare module.exports: any;
}
declare module 'babel-loader/lib/utils/exists' {
declare module.exports: any;
}
declare module 'babel-loader/lib/utils/read' {
declare module.exports: any;
}
declare module 'babel-loader/lib/utils/relative' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-loader/lib/fs-cache.js' {
declare module.exports: $Exports<'babel-loader/lib/fs-cache'>;
}
declare module 'babel-loader/lib/index.js' {
declare module.exports: $Exports<'babel-loader/lib/index'>;
}
declare module 'babel-loader/lib/resolve-rc.js' {
declare module.exports: $Exports<'babel-loader/lib/resolve-rc'>;
}
declare module 'babel-loader/lib/utils/exists.js' {
declare module.exports: $Exports<'babel-loader/lib/utils/exists'>;
}
declare module 'babel-loader/lib/utils/read.js' {
declare module.exports: $Exports<'babel-loader/lib/utils/read'>;
}
declare module 'babel-loader/lib/utils/relative.js' {
declare module.exports: $Exports<'babel-loader/lib/utils/relative'>;
}

View file

@ -0,0 +1,81 @@
// flow-typed signature: ef8e8ad61abd95bef9ea072c0bdb3d98
// flow-typed version: <<STUB>>/babel-plugin-module-resolver_v^3.0.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-plugin-module-resolver'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-plugin-module-resolver' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-plugin-module-resolver/lib/index' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/log' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/mapToRelative' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/normalizeOptions' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/resolvePath' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/transformers/call' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/transformers/import' {
declare module.exports: any;
}
declare module 'babel-plugin-module-resolver/lib/utils' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-plugin-module-resolver/lib/index.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/index'>;
}
declare module 'babel-plugin-module-resolver/lib/log.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/log'>;
}
declare module 'babel-plugin-module-resolver/lib/mapToRelative.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/mapToRelative'>;
}
declare module 'babel-plugin-module-resolver/lib/normalizeOptions.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/normalizeOptions'>;
}
declare module 'babel-plugin-module-resolver/lib/resolvePath.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/resolvePath'>;
}
declare module 'babel-plugin-module-resolver/lib/transformers/call.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/transformers/call'>;
}
declare module 'babel-plugin-module-resolver/lib/transformers/import.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/transformers/import'>;
}
declare module 'babel-plugin-module-resolver/lib/utils.js' {
declare module.exports: $Exports<'babel-plugin-module-resolver/lib/utils'>;
}

View file

@ -0,0 +1,32 @@
// flow-typed signature: acec4d6ed4d2870478d3cbe333f79115
// flow-typed version: <<STUB>>/babel-plugin-transform-flow-comments_v^6.17.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-plugin-transform-flow-comments'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-plugin-transform-flow-comments' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-plugin-transform-flow-comments/lib/index' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-plugin-transform-flow-comments/lib/index.js' {
declare module.exports: $Exports<'babel-plugin-transform-flow-comments/lib/index'>;
}

View file

@ -0,0 +1,88 @@
// flow-typed signature: 1a890b0eb44450a184610ef421a6c13a
// flow-typed version: <<STUB>>/babel-preset-env_v^1.6.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-preset-env'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-preset-env' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-preset-env/data/built-in-features' {
declare module.exports: any;
}
declare module 'babel-preset-env/data/plugin-features' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/default-includes' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/index' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/module-transformations' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/normalize-options' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/targets-parser' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/transform-polyfill-require-plugin' {
declare module.exports: any;
}
declare module 'babel-preset-env/lib/utils' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-preset-env/data/built-in-features.js' {
declare module.exports: $Exports<'babel-preset-env/data/built-in-features'>;
}
declare module 'babel-preset-env/data/plugin-features.js' {
declare module.exports: $Exports<'babel-preset-env/data/plugin-features'>;
}
declare module 'babel-preset-env/lib/default-includes.js' {
declare module.exports: $Exports<'babel-preset-env/lib/default-includes'>;
}
declare module 'babel-preset-env/lib/index.js' {
declare module.exports: $Exports<'babel-preset-env/lib/index'>;
}
declare module 'babel-preset-env/lib/module-transformations.js' {
declare module.exports: $Exports<'babel-preset-env/lib/module-transformations'>;
}
declare module 'babel-preset-env/lib/normalize-options.js' {
declare module.exports: $Exports<'babel-preset-env/lib/normalize-options'>;
}
declare module 'babel-preset-env/lib/targets-parser.js' {
declare module.exports: $Exports<'babel-preset-env/lib/targets-parser'>;
}
declare module 'babel-preset-env/lib/transform-polyfill-require-plugin.js' {
declare module.exports: $Exports<'babel-preset-env/lib/transform-polyfill-require-plugin'>;
}
declare module 'babel-preset-env/lib/utils.js' {
declare module.exports: $Exports<'babel-preset-env/lib/utils'>;
}

View file

@ -0,0 +1,32 @@
// flow-typed signature: 3ebdc081e66800c1a33e3acb6581ff3c
// flow-typed version: <<STUB>>/babel-preset-stage-2_v^6.18.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'babel-preset-stage-2'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'babel-preset-stage-2' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'babel-preset-stage-2/lib/index' {
declare module.exports: any;
}
// Filename aliases
declare module 'babel-preset-stage-2/lib/index.js' {
declare module.exports: $Exports<'babel-preset-stage-2/lib/index'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: 68331cab0e933e8a4092d45cad04cdea
// flow-typed version: <<STUB>>/eslint-config-standard-jsx_v^6.0.2/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-config-standard-jsx'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-config-standard-jsx' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'eslint-config-standard-jsx/index' {
declare module.exports: $Exports<'eslint-config-standard-jsx'>;
}
declare module 'eslint-config-standard-jsx/index.js' {
declare module.exports: $Exports<'eslint-config-standard-jsx'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: b7df2bd0c8381e6822c8dd629b61d47b
// flow-typed version: <<STUB>>/eslint-config-standard_v^12.0.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-config-standard'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-config-standard' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'eslint-config-standard/index' {
declare module.exports: $Exports<'eslint-config-standard'>;
}
declare module 'eslint-config-standard/index.js' {
declare module.exports: $Exports<'eslint-config-standard'>;
}

View file

@ -0,0 +1,424 @@
// flow-typed signature: 78b00087ab3122dabc1f491e91e21dc3
// flow-typed version: <<STUB>>/eslint-plugin-flowtype_v^2.46.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-flowtype'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-flowtype' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-flowtype/bin/readmeAssertions' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/isSimpleType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/needWrap' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleComplexType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleSimpleType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/booleanStyle' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/defineFlowType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/delimiterDangle' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/genericSpacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/newlineAfterFlowAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noDupeKeys' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noExistentialType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noFlowFixMeComments' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noMutableArray' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noPrimitiveConstructorTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noTypesMissingFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noUnusedExpressions' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/noWeakTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/objectTypeDelimiter' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireExactType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireParameterType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireReturnType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireTypesAtTop' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireValidFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireVariableType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/semi' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/sortKeys' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceAfterTypeColon' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeGenericBracket' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeTypeColon' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateFunctions' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeIndexer' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeProperty' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateReturnType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypeCastExpression' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypical' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateVariables' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/reporter' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeIdMatch' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeImportStyle' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/unionIntersectionSpacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/useFlowType' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/rules/validSyntax' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/checkFlowFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/fuzzyStringMatch' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getParameterName' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenAfterParens' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenBeforeParens' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFile' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/quoteName' {
declare module.exports: any;
}
declare module 'eslint-plugin-flowtype/dist/utilities/spacingFixers' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-flowtype/bin/readmeAssertions.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/bin/readmeAssertions'>;
}
declare module 'eslint-plugin-flowtype/dist/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/index'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyle/index'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/isSimpleType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyle/isSimpleType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyle/needWrap.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyle/needWrap'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleComplexType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyleComplexType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/arrayStyleSimpleType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/arrayStyleSimpleType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/booleanStyle.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/booleanStyle'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/defineFlowType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/defineFlowType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/delimiterDangle.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/delimiterDangle'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/genericSpacing.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/genericSpacing'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/newlineAfterFlowAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/newlineAfterFlowAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noDupeKeys.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noDupeKeys'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noExistentialType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noExistentialType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noFlowFixMeComments.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noFlowFixMeComments'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noMutableArray.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noMutableArray'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noPrimitiveConstructorTypes.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noPrimitiveConstructorTypes'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noTypesMissingFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noTypesMissingFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noUnusedExpressions.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noUnusedExpressions'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/noWeakTypes.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/noWeakTypes'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/objectTypeDelimiter.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/objectTypeDelimiter'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireExactType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireExactType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireParameterType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireParameterType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireReturnType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireReturnType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireTypesAtTop.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireTypesAtTop'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireValidFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireValidFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/requireVariableType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/requireVariableType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/semi.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/semi'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/sortKeys.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/sortKeys'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceAfterTypeColon.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/spaceAfterTypeColon'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeGenericBracket.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/spaceBeforeGenericBracket'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/spaceBeforeTypeColon.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/spaceBeforeTypeColon'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateFunctions.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateFunctions'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeIndexer.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeIndexer'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeProperty.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateObjectTypeProperty'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateReturnType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateReturnType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypeCastExpression.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypeCastExpression'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypical.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateTypical'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateVariables.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/evaluateVariables'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/index'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeColonSpacing/reporter.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeColonSpacing/reporter'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeIdMatch.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeIdMatch'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/typeImportStyle.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/typeImportStyle'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/unionIntersectionSpacing.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/unionIntersectionSpacing'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/useFlowType.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/useFlowType'>;
}
declare module 'eslint-plugin-flowtype/dist/rules/validSyntax.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/rules/validSyntax'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/checkFlowFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/checkFlowFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/fuzzyStringMatch.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/fuzzyStringMatch'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getParameterName.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/getParameterName'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenAfterParens.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/getTokenAfterParens'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/getTokenBeforeParens.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/getTokenBeforeParens'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/index.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/index'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFile.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isFlowFile'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/isFlowFileAnnotation'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/iterateFunctionNodes'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/quoteName.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/quoteName'>;
}
declare module 'eslint-plugin-flowtype/dist/utilities/spacingFixers.js' {
declare module.exports: $Exports<'eslint-plugin-flowtype/dist/utilities/spacingFixers'>;
}

View file

@ -0,0 +1,417 @@
// flow-typed signature: cc9510b23781c7e4a1d9ea9482254922
// flow-typed version: <<STUB>>/eslint-plugin-import_v^2.17.2/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-import'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-import' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-import/config/electron' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/errors' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/react-native' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/react' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/recommended' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/stage-0' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/typescript' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/config/warnings' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/core/importType' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/core/staticRequire' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/docsUrl' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/ExportMap' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/importDeclaration' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/default' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/dynamic-import-chunkname' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/exports-last' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/extensions' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/first' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/group-exports' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/imports-first' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/max-dependencies' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/named' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/namespace' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/newline-after-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-absolute-path' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-amd' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-anonymous-default-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-commonjs' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-cycle' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-default-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-deprecated' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-duplicates' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-dynamic-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-extraneous-dependencies' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-internal-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-mutable-exports' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default-member' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-default' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-named-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-namespace' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-nodejs-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-relative-parent-imports' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-restricted-paths' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-self-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-unassigned-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-unresolved' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-unused-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-useless-path-segments' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/no-webpack-loader-syntax' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/order' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/prefer-default-export' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/lib/rules/unambiguous' {
declare module.exports: any;
}
declare module 'eslint-plugin-import/memo-parser/index' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-import/config/electron.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/electron'>;
}
declare module 'eslint-plugin-import/config/errors.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/errors'>;
}
declare module 'eslint-plugin-import/config/react-native.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/react-native'>;
}
declare module 'eslint-plugin-import/config/react.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/react'>;
}
declare module 'eslint-plugin-import/config/recommended.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/recommended'>;
}
declare module 'eslint-plugin-import/config/stage-0.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/stage-0'>;
}
declare module 'eslint-plugin-import/config/typescript.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/typescript'>;
}
declare module 'eslint-plugin-import/config/warnings.js' {
declare module.exports: $Exports<'eslint-plugin-import/config/warnings'>;
}
declare module 'eslint-plugin-import/lib/core/importType.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/core/importType'>;
}
declare module 'eslint-plugin-import/lib/core/staticRequire.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/core/staticRequire'>;
}
declare module 'eslint-plugin-import/lib/docsUrl.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/docsUrl'>;
}
declare module 'eslint-plugin-import/lib/ExportMap.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/ExportMap'>;
}
declare module 'eslint-plugin-import/lib/importDeclaration.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/importDeclaration'>;
}
declare module 'eslint-plugin-import/lib/index.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/index'>;
}
declare module 'eslint-plugin-import/lib/rules/default.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/default'>;
}
declare module 'eslint-plugin-import/lib/rules/dynamic-import-chunkname.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/dynamic-import-chunkname'>;
}
declare module 'eslint-plugin-import/lib/rules/export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/export'>;
}
declare module 'eslint-plugin-import/lib/rules/exports-last.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/exports-last'>;
}
declare module 'eslint-plugin-import/lib/rules/extensions.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/extensions'>;
}
declare module 'eslint-plugin-import/lib/rules/first.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/first'>;
}
declare module 'eslint-plugin-import/lib/rules/group-exports.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/group-exports'>;
}
declare module 'eslint-plugin-import/lib/rules/imports-first.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/imports-first'>;
}
declare module 'eslint-plugin-import/lib/rules/max-dependencies.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/max-dependencies'>;
}
declare module 'eslint-plugin-import/lib/rules/named.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/named'>;
}
declare module 'eslint-plugin-import/lib/rules/namespace.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/namespace'>;
}
declare module 'eslint-plugin-import/lib/rules/newline-after-import.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/newline-after-import'>;
}
declare module 'eslint-plugin-import/lib/rules/no-absolute-path.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-absolute-path'>;
}
declare module 'eslint-plugin-import/lib/rules/no-amd.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-amd'>;
}
declare module 'eslint-plugin-import/lib/rules/no-anonymous-default-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-anonymous-default-export'>;
}
declare module 'eslint-plugin-import/lib/rules/no-commonjs.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-commonjs'>;
}
declare module 'eslint-plugin-import/lib/rules/no-cycle.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-cycle'>;
}
declare module 'eslint-plugin-import/lib/rules/no-default-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-default-export'>;
}
declare module 'eslint-plugin-import/lib/rules/no-deprecated.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-deprecated'>;
}
declare module 'eslint-plugin-import/lib/rules/no-duplicates.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-duplicates'>;
}
declare module 'eslint-plugin-import/lib/rules/no-dynamic-require.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-dynamic-require'>;
}
declare module 'eslint-plugin-import/lib/rules/no-extraneous-dependencies.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-extraneous-dependencies'>;
}
declare module 'eslint-plugin-import/lib/rules/no-internal-modules.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-internal-modules'>;
}
declare module 'eslint-plugin-import/lib/rules/no-mutable-exports.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-mutable-exports'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default-member.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-as-default-member'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-as-default.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-as-default'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-default.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-default'>;
}
declare module 'eslint-plugin-import/lib/rules/no-named-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-named-export'>;
}
declare module 'eslint-plugin-import/lib/rules/no-namespace.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-namespace'>;
}
declare module 'eslint-plugin-import/lib/rules/no-nodejs-modules.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-nodejs-modules'>;
}
declare module 'eslint-plugin-import/lib/rules/no-relative-parent-imports.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-relative-parent-imports'>;
}
declare module 'eslint-plugin-import/lib/rules/no-restricted-paths.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-restricted-paths'>;
}
declare module 'eslint-plugin-import/lib/rules/no-self-import.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-self-import'>;
}
declare module 'eslint-plugin-import/lib/rules/no-unassigned-import.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-unassigned-import'>;
}
declare module 'eslint-plugin-import/lib/rules/no-unresolved.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-unresolved'>;
}
declare module 'eslint-plugin-import/lib/rules/no-unused-modules.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-unused-modules'>;
}
declare module 'eslint-plugin-import/lib/rules/no-useless-path-segments.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-useless-path-segments'>;
}
declare module 'eslint-plugin-import/lib/rules/no-webpack-loader-syntax.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/no-webpack-loader-syntax'>;
}
declare module 'eslint-plugin-import/lib/rules/order.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/order'>;
}
declare module 'eslint-plugin-import/lib/rules/prefer-default-export.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/prefer-default-export'>;
}
declare module 'eslint-plugin-import/lib/rules/unambiguous.js' {
declare module.exports: $Exports<'eslint-plugin-import/lib/rules/unambiguous'>;
}
declare module 'eslint-plugin-import/memo-parser/index.js' {
declare module.exports: $Exports<'eslint-plugin-import/memo-parser/index'>;
}

View file

@ -0,0 +1,333 @@
// flow-typed signature: a4fea72b146e0dd4b94dcadb805fd976
// flow-typed version: <<STUB>>/eslint-plugin-node_v^8.0.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-node'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-node' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-node/lib/index' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/exports-style' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-deprecated-api' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-hide-core-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-bin' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-import' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-require' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-builtins' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-syntax' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/node-builtins' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/buffer' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/console' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/process' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-decoder' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-encoder' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url-search-params' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/process-exit-as-throw' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/rules/shebang' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/cache' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-existence' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-extraneous' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-prefer-global' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-publish' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/check-unsupported-builtins' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/enumerate-property-names' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/exists' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-allow-modules' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-configured-node-version' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-convert-path' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-import-export-targets' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-npmignore' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-package-json' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-require-targets' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-resolve-paths' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-semver-range' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/get-try-extensions' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/import-target' {
declare module.exports: any;
}
declare module 'eslint-plugin-node/lib/util/strip-import-path-params' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-node/lib/index.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/index'>;
}
declare module 'eslint-plugin-node/lib/rules/exports-style.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/exports-style'>;
}
declare module 'eslint-plugin-node/lib/rules/no-deprecated-api.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-deprecated-api'>;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-import.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-extraneous-import'>;
}
declare module 'eslint-plugin-node/lib/rules/no-extraneous-require.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-extraneous-require'>;
}
declare module 'eslint-plugin-node/lib/rules/no-hide-core-modules.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-hide-core-modules'>;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-import.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-missing-import'>;
}
declare module 'eslint-plugin-node/lib/rules/no-missing-require.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-missing-require'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-bin.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unpublished-bin'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-import.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unpublished-import'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unpublished-require.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unpublished-require'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-builtins.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features/es-builtins'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/es-syntax.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features/es-syntax'>;
}
declare module 'eslint-plugin-node/lib/rules/no-unsupported-features/node-builtins.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/no-unsupported-features/node-builtins'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/buffer.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/buffer'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/console.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/console'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/process.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/process'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-decoder.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/text-decoder'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/text-encoder.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/text-encoder'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url-search-params.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/url-search-params'>;
}
declare module 'eslint-plugin-node/lib/rules/prefer-global/url.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/prefer-global/url'>;
}
declare module 'eslint-plugin-node/lib/rules/process-exit-as-throw.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/process-exit-as-throw'>;
}
declare module 'eslint-plugin-node/lib/rules/shebang.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/rules/shebang'>;
}
declare module 'eslint-plugin-node/lib/util/cache.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/cache'>;
}
declare module 'eslint-plugin-node/lib/util/check-existence.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-existence'>;
}
declare module 'eslint-plugin-node/lib/util/check-extraneous.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-extraneous'>;
}
declare module 'eslint-plugin-node/lib/util/check-prefer-global.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-prefer-global'>;
}
declare module 'eslint-plugin-node/lib/util/check-publish.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-publish'>;
}
declare module 'eslint-plugin-node/lib/util/check-unsupported-builtins.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/check-unsupported-builtins'>;
}
declare module 'eslint-plugin-node/lib/util/enumerate-property-names.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/enumerate-property-names'>;
}
declare module 'eslint-plugin-node/lib/util/exists.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/exists'>;
}
declare module 'eslint-plugin-node/lib/util/get-allow-modules.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-allow-modules'>;
}
declare module 'eslint-plugin-node/lib/util/get-configured-node-version.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-configured-node-version'>;
}
declare module 'eslint-plugin-node/lib/util/get-convert-path.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-convert-path'>;
}
declare module 'eslint-plugin-node/lib/util/get-import-export-targets.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-import-export-targets'>;
}
declare module 'eslint-plugin-node/lib/util/get-npmignore.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-npmignore'>;
}
declare module 'eslint-plugin-node/lib/util/get-package-json.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-package-json'>;
}
declare module 'eslint-plugin-node/lib/util/get-require-targets.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-require-targets'>;
}
declare module 'eslint-plugin-node/lib/util/get-resolve-paths.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-resolve-paths'>;
}
declare module 'eslint-plugin-node/lib/util/get-semver-range.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-semver-range'>;
}
declare module 'eslint-plugin-node/lib/util/get-try-extensions.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/get-try-extensions'>;
}
declare module 'eslint-plugin-node/lib/util/import-target.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/import-target'>;
}
declare module 'eslint-plugin-node/lib/util/strip-import-path-params.js' {
declare module.exports: $Exports<'eslint-plugin-node/lib/util/strip-import-path-params'>;
}

View file

@ -0,0 +1,185 @@
// flow-typed signature: dd15a042fcd40a1d0e6f424e827085b5
// flow-typed version: <<STUB>>/eslint-plugin-promise_v^4.1.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-promise'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-promise' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-promise/rules/always-return' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/avoid-new' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/catch-or-return' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/get-docs-url' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/has-promise-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-promise' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-named-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/is-promise' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/lib/promise-statics' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-callback-in-promise' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-native' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-nesting' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-new-statics' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-promise-in-callback' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-return-in-finally' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/no-return-wrap' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/param-names' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-callbacks' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-then' {
declare module.exports: any;
}
declare module 'eslint-plugin-promise/rules/valid-params' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-promise/index' {
declare module.exports: $Exports<'eslint-plugin-promise'>;
}
declare module 'eslint-plugin-promise/index.js' {
declare module.exports: $Exports<'eslint-plugin-promise'>;
}
declare module 'eslint-plugin-promise/rules/always-return.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/always-return'>;
}
declare module 'eslint-plugin-promise/rules/avoid-new.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/avoid-new'>;
}
declare module 'eslint-plugin-promise/rules/catch-or-return.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/catch-or-return'>;
}
declare module 'eslint-plugin-promise/rules/lib/get-docs-url.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/get-docs-url'>;
}
declare module 'eslint-plugin-promise/rules/lib/has-promise-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/has-promise-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-inside-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-inside-promise.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-inside-promise'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-named-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-named-callback'>;
}
declare module 'eslint-plugin-promise/rules/lib/is-promise.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/is-promise'>;
}
declare module 'eslint-plugin-promise/rules/lib/promise-statics.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/lib/promise-statics'>;
}
declare module 'eslint-plugin-promise/rules/no-callback-in-promise.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-callback-in-promise'>;
}
declare module 'eslint-plugin-promise/rules/no-native.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-native'>;
}
declare module 'eslint-plugin-promise/rules/no-nesting.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-nesting'>;
}
declare module 'eslint-plugin-promise/rules/no-new-statics.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-new-statics'>;
}
declare module 'eslint-plugin-promise/rules/no-promise-in-callback.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-promise-in-callback'>;
}
declare module 'eslint-plugin-promise/rules/no-return-in-finally.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-return-in-finally'>;
}
declare module 'eslint-plugin-promise/rules/no-return-wrap.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/no-return-wrap'>;
}
declare module 'eslint-plugin-promise/rules/param-names.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/param-names'>;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-callbacks.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/prefer-await-to-callbacks'>;
}
declare module 'eslint-plugin-promise/rules/prefer-await-to-then.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/prefer-await-to-then'>;
}
declare module 'eslint-plugin-promise/rules/valid-params.js' {
declare module.exports: $Exports<'eslint-plugin-promise/rules/valid-params'>;
}

View file

@ -0,0 +1,696 @@
// flow-typed signature: fc9dc51418188f7754f08351c66422d6
// flow-typed version: <<STUB>>/eslint-plugin-react_v^7.12.4/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-react'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-react' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-react/lib/rules/boolean-prop-naming' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/button-has-type' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/default-props-match-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/destructuring-assignment' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/display-name' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-component-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-dom-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-elements' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-foreign-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/forbid-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-boolean-value' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-child-element-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-bracket-location' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-tag-location' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-brace-presence' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-equals-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-filename-extension' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-first-prop-new-line' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-fragments' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-handler-names' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-key' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-depth' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-props-per-line' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-bind' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-comment-textnodes' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-duplicate-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-literals' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-target-blank' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-undef' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-one-expression-per-line' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-pascal-case' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-props-no-multi-spaces' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-default-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-space-before-closing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-tag-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-react' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-vars' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/jsx-wrap-multilines' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-access-state-in-setstate' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-array-index-key' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-children-prop' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-danger-with-children' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-danger' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-deprecated' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-did-mount-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-did-update-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-direct-mutation-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-find-dom-node' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-is-mounted' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-multi-comp' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-redundant-should-component-update' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-render-return-value' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-string-refs' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-this-in-sfc' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-typos' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unescaped-entities' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unknown-property' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unsafe' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/no-will-update-set-state' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/prefer-es6-class' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/prefer-stateless-function' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/react-in-jsx-scope' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/require-default-props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/require-optimization' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/require-render-return' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/self-closing-comp' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/sort-comp' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/sort-prop-types' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/style-prop-object' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/rules/void-dom-elements-no-children' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/annotations' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/ast' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/Components' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/defaultProps' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/docsUrl' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/error' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/getTokenBeforeClosingBracket' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/jsx' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/log' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/makeNoMethodSetStateRule' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/pragma' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/props' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/propTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/propWrapper' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/usedPropTypes' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/variable' {
declare module.exports: any;
}
declare module 'eslint-plugin-react/lib/util/version' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-react/index' {
declare module.exports: $Exports<'eslint-plugin-react'>;
}
declare module 'eslint-plugin-react/index.js' {
declare module.exports: $Exports<'eslint-plugin-react'>;
}
declare module 'eslint-plugin-react/lib/rules/boolean-prop-naming.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/boolean-prop-naming'>;
}
declare module 'eslint-plugin-react/lib/rules/button-has-type.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/button-has-type'>;
}
declare module 'eslint-plugin-react/lib/rules/default-props-match-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/default-props-match-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/destructuring-assignment.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/destructuring-assignment'>;
}
declare module 'eslint-plugin-react/lib/rules/display-name.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/display-name'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-component-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-component-props'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-dom-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-dom-props'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-elements.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-elements'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-foreign-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-foreign-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/forbid-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/forbid-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-boolean-value.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-boolean-value'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-child-element-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-child-element-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-bracket-location.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-closing-bracket-location'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-closing-tag-location.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-closing-tag-location'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-brace-presence.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-curly-brace-presence'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-curly-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-curly-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-equals-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-equals-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-filename-extension.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-filename-extension'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-first-prop-new-line.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-first-prop-new-line'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-fragments.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-fragments'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-handler-names.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-handler-names'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-indent-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-indent.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-indent'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-key.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-key'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-depth.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-max-depth'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-max-props-per-line.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-max-props-per-line'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-bind.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-bind'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-comment-textnodes.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-comment-textnodes'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-duplicate-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-duplicate-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-literals.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-literals'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-target-blank.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-target-blank'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-no-undef.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-no-undef'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-one-expression-per-line.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-one-expression-per-line'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-pascal-case.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-pascal-case'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-props-no-multi-spaces.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-props-no-multi-spaces'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-default-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-sort-default-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-sort-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-sort-props'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-space-before-closing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-space-before-closing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-tag-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-tag-spacing'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-react.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-uses-react'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-uses-vars.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-uses-vars'>;
}
declare module 'eslint-plugin-react/lib/rules/jsx-wrap-multilines.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/jsx-wrap-multilines'>;
}
declare module 'eslint-plugin-react/lib/rules/no-access-state-in-setstate.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-access-state-in-setstate'>;
}
declare module 'eslint-plugin-react/lib/rules/no-array-index-key.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-array-index-key'>;
}
declare module 'eslint-plugin-react/lib/rules/no-children-prop.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-children-prop'>;
}
declare module 'eslint-plugin-react/lib/rules/no-danger-with-children.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-danger-with-children'>;
}
declare module 'eslint-plugin-react/lib/rules/no-danger.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-danger'>;
}
declare module 'eslint-plugin-react/lib/rules/no-deprecated.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-deprecated'>;
}
declare module 'eslint-plugin-react/lib/rules/no-did-mount-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-did-mount-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-did-update-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-did-update-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-direct-mutation-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-direct-mutation-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-find-dom-node.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-find-dom-node'>;
}
declare module 'eslint-plugin-react/lib/rules/no-is-mounted.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-is-mounted'>;
}
declare module 'eslint-plugin-react/lib/rules/no-multi-comp.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-multi-comp'>;
}
declare module 'eslint-plugin-react/lib/rules/no-redundant-should-component-update.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-redundant-should-component-update'>;
}
declare module 'eslint-plugin-react/lib/rules/no-render-return-value.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-render-return-value'>;
}
declare module 'eslint-plugin-react/lib/rules/no-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-string-refs.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-string-refs'>;
}
declare module 'eslint-plugin-react/lib/rules/no-this-in-sfc.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-this-in-sfc'>;
}
declare module 'eslint-plugin-react/lib/rules/no-typos.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-typos'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unescaped-entities.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unescaped-entities'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unknown-property.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unknown-property'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unsafe.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unsafe'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unused-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/no-unused-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-unused-state'>;
}
declare module 'eslint-plugin-react/lib/rules/no-will-update-set-state.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/no-will-update-set-state'>;
}
declare module 'eslint-plugin-react/lib/rules/prefer-es6-class.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/prefer-es6-class'>;
}
declare module 'eslint-plugin-react/lib/rules/prefer-stateless-function.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/prefer-stateless-function'>;
}
declare module 'eslint-plugin-react/lib/rules/prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/react-in-jsx-scope.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/react-in-jsx-scope'>;
}
declare module 'eslint-plugin-react/lib/rules/require-default-props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/require-default-props'>;
}
declare module 'eslint-plugin-react/lib/rules/require-optimization.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/require-optimization'>;
}
declare module 'eslint-plugin-react/lib/rules/require-render-return.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/require-render-return'>;
}
declare module 'eslint-plugin-react/lib/rules/self-closing-comp.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/self-closing-comp'>;
}
declare module 'eslint-plugin-react/lib/rules/sort-comp.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/sort-comp'>;
}
declare module 'eslint-plugin-react/lib/rules/sort-prop-types.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/sort-prop-types'>;
}
declare module 'eslint-plugin-react/lib/rules/style-prop-object.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/style-prop-object'>;
}
declare module 'eslint-plugin-react/lib/rules/void-dom-elements-no-children.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/rules/void-dom-elements-no-children'>;
}
declare module 'eslint-plugin-react/lib/util/annotations.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/annotations'>;
}
declare module 'eslint-plugin-react/lib/util/ast.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/ast'>;
}
declare module 'eslint-plugin-react/lib/util/Components.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/Components'>;
}
declare module 'eslint-plugin-react/lib/util/defaultProps.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/defaultProps'>;
}
declare module 'eslint-plugin-react/lib/util/docsUrl.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/docsUrl'>;
}
declare module 'eslint-plugin-react/lib/util/error.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/error'>;
}
declare module 'eslint-plugin-react/lib/util/getTokenBeforeClosingBracket.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/getTokenBeforeClosingBracket'>;
}
declare module 'eslint-plugin-react/lib/util/jsx.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/jsx'>;
}
declare module 'eslint-plugin-react/lib/util/log.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/log'>;
}
declare module 'eslint-plugin-react/lib/util/makeNoMethodSetStateRule.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/makeNoMethodSetStateRule'>;
}
declare module 'eslint-plugin-react/lib/util/pragma.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/pragma'>;
}
declare module 'eslint-plugin-react/lib/util/props.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/props'>;
}
declare module 'eslint-plugin-react/lib/util/propTypes.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/propTypes'>;
}
declare module 'eslint-plugin-react/lib/util/propWrapper.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/propWrapper'>;
}
declare module 'eslint-plugin-react/lib/util/usedPropTypes.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/usedPropTypes'>;
}
declare module 'eslint-plugin-react/lib/util/variable.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/variable'>;
}
declare module 'eslint-plugin-react/lib/util/version.js' {
declare module.exports: $Exports<'eslint-plugin-react/lib/util/version'>;
}

View file

@ -0,0 +1,59 @@
// flow-typed signature: 59893df9239e2d9724a90756a6525968
// flow-typed version: <<STUB>>/eslint-plugin-standard_v^4.0.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'eslint-plugin-standard'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'eslint-plugin-standard' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'eslint-plugin-standard/rules/array-bracket-even-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-standard/rules/computed-property-even-spacing' {
declare module.exports: any;
}
declare module 'eslint-plugin-standard/rules/no-callback-literal' {
declare module.exports: any;
}
declare module 'eslint-plugin-standard/rules/object-curly-even-spacing' {
declare module.exports: any;
}
// Filename aliases
declare module 'eslint-plugin-standard/index' {
declare module.exports: $Exports<'eslint-plugin-standard'>;
}
declare module 'eslint-plugin-standard/index.js' {
declare module.exports: $Exports<'eslint-plugin-standard'>;
}
declare module 'eslint-plugin-standard/rules/array-bracket-even-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/array-bracket-even-spacing'>;
}
declare module 'eslint-plugin-standard/rules/computed-property-even-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/computed-property-even-spacing'>;
}
declare module 'eslint-plugin-standard/rules/no-callback-literal.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/no-callback-literal'>;
}
declare module 'eslint-plugin-standard/rules/object-curly-even-spacing.js' {
declare module.exports: $Exports<'eslint-plugin-standard/rules/object-curly-even-spacing'>;
}

2531
flow-typed/npm/eslint_vx.x.x.js vendored Normal file

File diff suppressed because it is too large Load diff

6
flow-typed/npm/flow-bin_v0.x.x.js vendored Normal file
View file

@ -0,0 +1,6 @@
// flow-typed signature: 6a5610678d4b01e13bbfbbc62bdaf583
// flow-typed version: 3817bc6980/flow-bin_v0.x.x/flow_>=v0.25.x
declare module "flow-bin" {
declare module.exports: string;
}

193
flow-typed/npm/flow-typed_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,193 @@
// flow-typed signature: b46df6a09b982fc599f51cedf4d8ef6b
// flow-typed version: <<STUB>>/flow-typed_v^2.5.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'flow-typed'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'flow-typed' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'flow-typed/dist/cli' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/create-stub' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/install' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/runTests' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/search' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/update-cache' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/update' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/validateDefs' {
declare module.exports: any;
}
declare module 'flow-typed/dist/commands/version' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/cacheRepoUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/codeSign' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/fileUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/flowProjectUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/flowVersion' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/git' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/github' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/isInFlowTypedRepo' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/libDefs' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/node' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/npm/npmLibDefs' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/npm/npmProjectUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/semver' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/stubUtils' {
declare module.exports: any;
}
declare module 'flow-typed/dist/lib/validationErrors' {
declare module.exports: any;
}
// Filename aliases
declare module 'flow-typed/dist/cli.js' {
declare module.exports: $Exports<'flow-typed/dist/cli'>;
}
declare module 'flow-typed/dist/commands/create-stub.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/create-stub'>;
}
declare module 'flow-typed/dist/commands/install.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/install'>;
}
declare module 'flow-typed/dist/commands/runTests.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/runTests'>;
}
declare module 'flow-typed/dist/commands/search.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/search'>;
}
declare module 'flow-typed/dist/commands/update-cache.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/update-cache'>;
}
declare module 'flow-typed/dist/commands/update.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/update'>;
}
declare module 'flow-typed/dist/commands/validateDefs.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/validateDefs'>;
}
declare module 'flow-typed/dist/commands/version.js' {
declare module.exports: $Exports<'flow-typed/dist/commands/version'>;
}
declare module 'flow-typed/dist/lib/cacheRepoUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/cacheRepoUtils'>;
}
declare module 'flow-typed/dist/lib/codeSign.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/codeSign'>;
}
declare module 'flow-typed/dist/lib/fileUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/fileUtils'>;
}
declare module 'flow-typed/dist/lib/flowProjectUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/flowProjectUtils'>;
}
declare module 'flow-typed/dist/lib/flowVersion.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/flowVersion'>;
}
declare module 'flow-typed/dist/lib/git.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/git'>;
}
declare module 'flow-typed/dist/lib/github.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/github'>;
}
declare module 'flow-typed/dist/lib/isInFlowTypedRepo.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/isInFlowTypedRepo'>;
}
declare module 'flow-typed/dist/lib/libDefs.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/libDefs'>;
}
declare module 'flow-typed/dist/lib/node.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/node'>;
}
declare module 'flow-typed/dist/lib/npm/npmLibDefs.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/npm/npmLibDefs'>;
}
declare module 'flow-typed/dist/lib/npm/npmProjectUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/npm/npmProjectUtils'>;
}
declare module 'flow-typed/dist/lib/semver.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/semver'>;
}
declare module 'flow-typed/dist/lib/stubUtils.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/stubUtils'>;
}
declare module 'flow-typed/dist/lib/validationErrors.js' {
declare module.exports: $Exports<'flow-typed/dist/lib/validationErrors'>;
}

88
flow-typed/npm/husky_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,88 @@
// flow-typed signature: 09dc7be6f5dfade9410350e5f356b1e6
// flow-typed version: <<STUB>>/husky_v^0.14.3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'husky'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'husky' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'husky/__tests__/index' {
declare module.exports: any;
}
declare module 'husky/bin/install' {
declare module.exports: any;
}
declare module 'husky/bin/uninstall' {
declare module.exports: any;
}
declare module 'husky/src/install' {
declare module.exports: any;
}
declare module 'husky/src/uninstall' {
declare module.exports: any;
}
declare module 'husky/src/utils/find-hooks-dir' {
declare module.exports: any;
}
declare module 'husky/src/utils/find-parent' {
declare module.exports: any;
}
declare module 'husky/src/utils/get-hook-script' {
declare module.exports: any;
}
declare module 'husky/src/utils/is-husky' {
declare module.exports: any;
}
// Filename aliases
declare module 'husky/__tests__/index.js' {
declare module.exports: $Exports<'husky/__tests__/index'>;
}
declare module 'husky/bin/install.js' {
declare module.exports: $Exports<'husky/bin/install'>;
}
declare module 'husky/bin/uninstall.js' {
declare module.exports: $Exports<'husky/bin/uninstall'>;
}
declare module 'husky/src/install.js' {
declare module.exports: $Exports<'husky/src/install'>;
}
declare module 'husky/src/uninstall.js' {
declare module.exports: $Exports<'husky/src/uninstall'>;
}
declare module 'husky/src/utils/find-hooks-dir.js' {
declare module.exports: $Exports<'husky/src/utils/find-hooks-dir'>;
}
declare module 'husky/src/utils/find-parent.js' {
declare module.exports: $Exports<'husky/src/utils/find-parent'>;
}
declare module 'husky/src/utils/get-hook-script.js' {
declare module.exports: $Exports<'husky/src/utils/get-hook-script'>;
}
declare module 'husky/src/utils/is-husky.js' {
declare module.exports: $Exports<'husky/src/utils/is-husky'>;
}

108
flow-typed/npm/lint-staged_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,108 @@
// flow-typed signature: 1b9179cadf091d93c5142d3673b2e210
// flow-typed version: <<STUB>>/lint-staged_v^7.0.4/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'lint-staged'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'lint-staged' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'lint-staged/src/calcChunkSize' {
declare module.exports: any;
}
declare module 'lint-staged/src/checkPkgScripts' {
declare module.exports: any;
}
declare module 'lint-staged/src/findBin' {
declare module.exports: any;
}
declare module 'lint-staged/src/generateTasks' {
declare module.exports: any;
}
declare module 'lint-staged/src/getConfig' {
declare module.exports: any;
}
declare module 'lint-staged/src/index' {
declare module.exports: any;
}
declare module 'lint-staged/src/makeCmdTasks' {
declare module.exports: any;
}
declare module 'lint-staged/src/printErrors' {
declare module.exports: any;
}
declare module 'lint-staged/src/resolveGitDir' {
declare module.exports: any;
}
declare module 'lint-staged/src/resolveTaskFn' {
declare module.exports: any;
}
declare module 'lint-staged/src/runAll' {
declare module.exports: any;
}
// Filename aliases
declare module 'lint-staged/index' {
declare module.exports: $Exports<'lint-staged'>;
}
declare module 'lint-staged/index.js' {
declare module.exports: $Exports<'lint-staged'>;
}
declare module 'lint-staged/src/calcChunkSize.js' {
declare module.exports: $Exports<'lint-staged/src/calcChunkSize'>;
}
declare module 'lint-staged/src/checkPkgScripts.js' {
declare module.exports: $Exports<'lint-staged/src/checkPkgScripts'>;
}
declare module 'lint-staged/src/findBin.js' {
declare module.exports: $Exports<'lint-staged/src/findBin'>;
}
declare module 'lint-staged/src/generateTasks.js' {
declare module.exports: $Exports<'lint-staged/src/generateTasks'>;
}
declare module 'lint-staged/src/getConfig.js' {
declare module.exports: $Exports<'lint-staged/src/getConfig'>;
}
declare module 'lint-staged/src/index.js' {
declare module.exports: $Exports<'lint-staged/src/index'>;
}
declare module 'lint-staged/src/makeCmdTasks.js' {
declare module.exports: $Exports<'lint-staged/src/makeCmdTasks'>;
}
declare module 'lint-staged/src/printErrors.js' {
declare module.exports: $Exports<'lint-staged/src/printErrors'>;
}
declare module 'lint-staged/src/resolveGitDir.js' {
declare module.exports: $Exports<'lint-staged/src/resolveGitDir'>;
}
declare module 'lint-staged/src/resolveTaskFn.js' {
declare module.exports: $Exports<'lint-staged/src/resolveTaskFn'>;
}
declare module 'lint-staged/src/runAll.js' {
declare module.exports: $Exports<'lint-staged/src/runAll'>;
}

178
flow-typed/npm/prettier_v1.x.x.js vendored Normal file
View file

@ -0,0 +1,178 @@
// flow-typed signature: 066c92e9ccb5f0711df8d73cbca837d6
// flow-typed version: 9e32affdbd/prettier_v1.x.x/flow_>=v0.56.x
declare module "prettier" {
declare export type AST = Object;
declare export type Doc = Object;
declare export type FastPath = Object;
declare export type PrettierParserName =
| "babylon"
| "flow"
| "typescript"
| "postcss"
| "css"
| "less"
| "scss"
| "json"
| "graphql"
| "markdown"
| "vue";
declare export type PrettierParser = {
[name: PrettierParserName]: (text: string, options?: Object) => AST
};
declare export type CustomParser = (
text: string,
parsers: PrettierParser,
options: Options
) => AST;
declare export type Options = {|
printWidth?: number,
tabWidth?: number,
useTabs?: boolean,
semi?: boolean,
singleQuote?: boolean,
trailingComma?: "none" | "es5" | "all",
bracketSpacing?: boolean,
jsxBracketSameLine?: boolean,
arrowParens?: "avoid" | "always",
rangeStart?: number,
rangeEnd?: number,
parser?: PrettierParserName | CustomParser,
filepath?: string,
requirePragma?: boolean,
insertPragma?: boolean,
proseWrap?: "always" | "never" | "preserve",
plugins?: Array<string | Plugin>
|};
declare export type Plugin = {
languages: SupportLanguage,
parsers: { [parserName: string]: Parser },
printers: { [astFormat: string]: Printer }
};
declare export type Parser = {
parse: (
text: string,
parsers: { [parserName: string]: Parser },
options: Object
) => AST,
astFormat: string
};
declare export type Printer = {
print: (
path: FastPath,
options: Object,
print: (path: FastPath) => Doc
) => Doc,
embed: (
path: FastPath,
print: (path: FastPath) => Doc,
textToDoc: (text: string, options: Object) => Doc,
options: Object
) => ?Doc
};
declare export type CursorOptions = {|
cursorOffset: number,
printWidth?: $PropertyType<Options, "printWidth">,
tabWidth?: $PropertyType<Options, "tabWidth">,
useTabs?: $PropertyType<Options, "useTabs">,
semi?: $PropertyType<Options, "semi">,
singleQuote?: $PropertyType<Options, "singleQuote">,
trailingComma?: $PropertyType<Options, "trailingComma">,
bracketSpacing?: $PropertyType<Options, "bracketSpacing">,
jsxBracketSameLine?: $PropertyType<Options, "jsxBracketSameLine">,
arrowParens?: $PropertyType<Options, "arrowParens">,
parser?: $PropertyType<Options, "parser">,
filepath?: $PropertyType<Options, "filepath">,
requirePragma?: $PropertyType<Options, "requirePragma">,
insertPragma?: $PropertyType<Options, "insertPragma">,
proseWrap?: $PropertyType<Options, "proseWrap">,
plugins?: $PropertyType<Options, "plugins">
|};
declare export type CursorResult = {|
formatted: string,
cursorOffset: number
|};
declare export type ResolveConfigOptions = {|
useCache?: boolean,
config?: string,
editorconfig?: boolean
|};
declare export type SupportLanguage = {
name: string,
since: string,
parsers: Array<string>,
group?: string,
tmScope: string,
aceMode: string,
codemirrorMode: string,
codemirrorMimeType: string,
aliases?: Array<string>,
extensions: Array<string>,
filenames?: Array<string>,
linguistLanguageId: number,
vscodeLanguageIds: Array<string>
};
declare export type SupportOption = {|
since: string,
type: "int" | "boolean" | "choice" | "path",
deprecated?: string,
redirect?: SupportOptionRedirect,
description: string,
oppositeDescription?: string,
default: SupportOptionValue,
range?: SupportOptionRange,
choices?: SupportOptionChoice
|};
declare export type SupportOptionRedirect = {|
options: string,
value: SupportOptionValue
|};
declare export type SupportOptionRange = {|
start: number,
end: number,
step: number
|};
declare export type SupportOptionChoice = {|
value: boolean | string,
description?: string,
since?: string,
deprecated?: string,
redirect?: SupportOptionValue
|};
declare export type SupportOptionValue = number | boolean | string;
declare export type SupportInfo = {|
languages: Array<SupportLanguage>,
options: Array<SupportOption>
|};
declare export type Prettier = {|
format: (source: string, options?: Options) => string,
check: (source: string, options?: Options) => boolean,
formatWithCursor: (source: string, options: CursorOptions) => CursorResult,
resolveConfig: {
(filePath: string, options?: ResolveConfigOptions): Promise<?Options>,
sync(filePath: string, options?: ResolveConfigOptions): ?Options
},
clearConfigCache: () => void,
getSupportInfo: (version?: string) => SupportInfo
|};
declare export default Prettier;
}

46
flow-typed/npm/proxy-polyfill_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,46 @@
// flow-typed signature: 85f3cee3ef579fc4277423833cd8f304
// flow-typed version: <<STUB>>/proxy-polyfill_v0.1.6/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'proxy-polyfill'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'proxy-polyfill' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'proxy-polyfill/proxy' {
declare module.exports: any;
}
declare module 'proxy-polyfill/proxy.min' {
declare module.exports: any;
}
declare module 'proxy-polyfill/suite' {
declare module.exports: any;
}
// Filename aliases
declare module 'proxy-polyfill/proxy.js' {
declare module.exports: $Exports<'proxy-polyfill/proxy'>;
}
declare module 'proxy-polyfill/proxy.min.js' {
declare module.exports: $Exports<'proxy-polyfill/proxy.min'>;
}
declare module 'proxy-polyfill/suite.js' {
declare module.exports: $Exports<'proxy-polyfill/suite'>;
}

View file

@ -0,0 +1,74 @@
// flow-typed signature: f394c50a048b5a7ebd278b90412df2ed
// flow-typed version: <<STUB>>/rollup-plugin-babel_v3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-babel'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-babel' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.cjs' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.es' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/constants' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/helperPlugin' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/index' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/preflightCheck' {
declare module.exports: any;
}
declare module 'rollup-plugin-babel/src/utils' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.cjs.js' {
declare module.exports: $Exports<'rollup-plugin-babel/dist/rollup-plugin-babel.cjs'>;
}
declare module 'rollup-plugin-babel/dist/rollup-plugin-babel.es.js' {
declare module.exports: $Exports<'rollup-plugin-babel/dist/rollup-plugin-babel.es'>;
}
declare module 'rollup-plugin-babel/src/constants.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/constants'>;
}
declare module 'rollup-plugin-babel/src/helperPlugin.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/helperPlugin'>;
}
declare module 'rollup-plugin-babel/src/index.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/index'>;
}
declare module 'rollup-plugin-babel/src/preflightCheck.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/preflightCheck'>;
}
declare module 'rollup-plugin-babel/src/utils.js' {
declare module.exports: $Exports<'rollup-plugin-babel/src/utils'>;
}

View file

@ -0,0 +1,39 @@
// flow-typed signature: 0b11a12fd929a3a3afd136d42a652bd9
// flow-typed version: <<STUB>>/rollup-plugin-copy_v^1.1.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-copy'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-copy' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup-plugin-copy/dist/index.commonjs' {
declare module.exports: any;
}
declare module 'rollup-plugin-copy/dist/index.module' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup-plugin-copy/dist/index.commonjs.js' {
declare module.exports: $Exports<'rollup-plugin-copy/dist/index.commonjs'>;
}
declare module 'rollup-plugin-copy/dist/index.module.js' {
declare module.exports: $Exports<'rollup-plugin-copy/dist/index.module'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: 57ac4a4687dd0b10d420e17d2d30e534
// flow-typed version: <<STUB>>/rollup-plugin-eslint_v^5.1.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-eslint'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-eslint' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'rollup-plugin-eslint/index' {
declare module.exports: $Exports<'rollup-plugin-eslint'>;
}
declare module 'rollup-plugin-eslint/index.js' {
declare module.exports: $Exports<'rollup-plugin-eslint'>;
}

View file

@ -0,0 +1,33 @@
// flow-typed signature: 25586f0fba8b577d1a0f5bd6b4167dae
// flow-typed version: <<STUB>>/rollup-plugin-flow_v^1.1.1/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-flow'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-flow' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
// Filename aliases
declare module 'rollup-plugin-flow/index' {
declare module.exports: $Exports<'rollup-plugin-flow'>;
}
declare module 'rollup-plugin-flow/index.js' {
declare module.exports: $Exports<'rollup-plugin-flow'>;
}

View file

@ -0,0 +1,39 @@
// flow-typed signature: a36cd847454eb7e3f098cadbd0745e0a
// flow-typed version: <<STUB>>/rollup-plugin-includepaths_v^0.2.3/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup-plugin-includepaths'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup-plugin-includepaths' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup-plugin-includepaths/src/plugin.es5' {
declare module.exports: any;
}
declare module 'rollup-plugin-includepaths/src/plugin' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup-plugin-includepaths/src/plugin.es5.js' {
declare module.exports: $Exports<'rollup-plugin-includepaths/src/plugin.es5'>;
}
declare module 'rollup-plugin-includepaths/src/plugin.js' {
declare module.exports: $Exports<'rollup-plugin-includepaths/src/plugin'>;
}

53
flow-typed/npm/rollup_vx.x.x.js vendored Normal file
View file

@ -0,0 +1,53 @@
// flow-typed signature: e8ee84a58128c679bea1b5976f7f00cf
// flow-typed version: <<STUB>>/rollup_v^1.8.0/flow_v0.97.0
/**
* This is an autogenerated libdef stub for:
*
* 'rollup'
*
* Fill this stub out by replacing all the `any` types.
*
* Once filled out, we encourage you to share your work with the
* community by sending a pull request to:
* https://github.com/flowtype/flow-typed
*/
declare module 'rollup' {
declare module.exports: any;
}
/**
* We include stubs for each file inside this npm package in case you need to
* require those files directly. Feel free to delete any files that aren't
* needed.
*/
declare module 'rollup/dist/rollup.browser.es' {
declare module.exports: any;
}
declare module 'rollup/dist/rollup.browser' {
declare module.exports: any;
}
declare module 'rollup/dist/rollup.es' {
declare module.exports: any;
}
declare module 'rollup/dist/rollup' {
declare module.exports: any;
}
// Filename aliases
declare module 'rollup/dist/rollup.browser.es.js' {
declare module.exports: $Exports<'rollup/dist/rollup.browser.es'>;
}
declare module 'rollup/dist/rollup.browser.js' {
declare module.exports: $Exports<'rollup/dist/rollup.browser'>;
}
declare module 'rollup/dist/rollup.es.js' {
declare module.exports: $Exports<'rollup/dist/rollup.es'>;
}
declare module 'rollup/dist/rollup.js' {
declare module.exports: $Exports<'rollup/dist/rollup'>;
}

102
flow-typed/npm/uuid_v3.x.x.js vendored Normal file
View file

@ -0,0 +1,102 @@
// flow-typed signature: 3cf668e64747095cab0bb360cf2fb34f
// flow-typed version: d659bd0cb8/uuid_v3.x.x/flow_>=v0.32.x
declare module "uuid" {
declare class uuid {
static (
options?: {|
random?: number[],
rng?: () => number[] | Buffer
|},
buffer?: number[] | Buffer,
offset?: number
): string,
static v1(
options?: {|
node?: number[],
clockseq?: number,
msecs?: number | Date,
nsecs?: number
|},
buffer?: number[] | Buffer,
offset?: number
): string,
static v4(
options?: {|
random?: number[],
rng?: () => number[] | Buffer
|},
buffer?: number[] | Buffer,
offset?: number
): string
}
declare module.exports: Class<uuid>;
}
declare module "uuid/v1" {
declare class v1 {
static (
options?: {|
node?: number[],
clockseq?: number,
msecs?: number | Date,
nsecs?: number
|},
buffer?: number[] | Buffer,
offset?: number
): string
}
declare module.exports: Class<v1>;
}
declare module "uuid/v3" {
declare class v3 {
static (
name?: string | number[],
namespace?: string | number[],
buffer?: number[] | Buffer,
offset?: number
): string,
static name: string,
static DNS: string,
static URL: string
}
declare module.exports: Class<v3>;
}
declare module "uuid/v4" {
declare class v4 {
static (
options?: {|
random?: number[],
rng?: () => number[] | Buffer
|},
buffer?: number[] | Buffer,
offset?: number
): string
}
declare module.exports: Class<v4>;
}
declare module "uuid/v5" {
declare class v5 {
static (
name?: string | number[],
namespace?: string | number[],
buffer?: number[] | Buffer,
offset?: number
): string,
static name: string,
static DNS: string,
static URL: string
}
declare module.exports: Class<v5>;
}

6
flow-typed/reselect.js vendored Normal file
View file

@ -0,0 +1,6 @@
// @flow
// We should be using the `reselect` that comes with flow-typed but it's going to take a ton of work to get that working
// without any errors. For now it's any type
declare module 'reselect' {
declare module.exports: any;
}

View file

@ -21,9 +21,9 @@
"main": "dist/bundle.js", "main": "dist/bundle.js",
"module": "dist/bundle.es.js", "module": "dist/bundle.es.js",
"scripts": { "scripts": {
"build": "rollup --config && webpack", "build": "rollup --config",
"dev": "webpack --watch", "dev": "rollup --config --watch",
"precommit": "lint-staged", "precommit": "flow check && lint-staged",
"lint": "eslint 'src/**/*.js' --fix", "lint": "eslint 'src/**/*.js' --fix",
"format": "prettier 'src/**/*.{js,json}' --write" "format": "prettier 'src/**/*.{js,json}' --write"
}, },
@ -40,25 +40,26 @@
"babel-plugin-transform-flow-comments": "^6.17.0", "babel-plugin-transform-flow-comments": "^6.17.0",
"babel-preset-env": "^1.6.1", "babel-preset-env": "^1.6.1",
"babel-preset-stage-2": "^6.18.0", "babel-preset-stage-2": "^6.18.0",
"eslint": "^4.19.1", "eslint": "^5.16.0",
"eslint-config-airbnb-base": "^12.1.0", "eslint-config-standard": "^12.0.0",
"eslint-config-prettier": "^2.9.0", "eslint-config-standard-jsx": "^6.0.2",
"eslint-import-resolver-webpack": "^0.9.0", "eslint-plugin-flowtype": "^2.46.1",
"eslint-plugin-flowtype": "^2.40.1", "eslint-plugin-import": "^2.17.2",
"eslint-plugin-import": "^2.10.0", "eslint-plugin-node": "^8.0.1",
"eslint-plugin-prettier": "^2.4.0", "eslint-plugin-promise": "^4.1.1",
"flow-bin": "^0.69.0", "eslint-plugin-react": "^7.12.4",
"eslint-plugin-standard": "^4.0.0",
"flow-bin": "^0.97.0",
"flow-typed": "^2.5.1", "flow-typed": "^2.5.1",
"flow-webpack-plugin": "^1.2.0",
"husky": "^0.14.3", "husky": "^0.14.3",
"lint-staged": "^7.0.4", "lint-staged": "^7.0.4",
"prettier": "^1.4.2", "prettier": "^1.4.2",
"rollup": "^1.8.0", "rollup": "^1.8.0",
"rollup-plugin-babel": "3", "rollup-plugin-babel": "3",
"rollup-plugin-copy": "^1.1.0",
"rollup-plugin-eslint": "^5.1.0",
"rollup-plugin-flow": "^1.1.1", "rollup-plugin-flow": "^1.1.1",
"rollup-plugin-includepaths": "^0.2.3", "rollup-plugin-includepaths": "^0.2.3"
"webpack": "^4.5.0",
"webpack-cli": "^2.0.14"
}, },
"engines": { "engines": {
"yarn": "^1.3" "yarn": "^1.3"

View file

@ -1,19 +1,20 @@
import babel from 'rollup-plugin-babel'; import babel from 'rollup-plugin-babel';
import flow from 'rollup-plugin-flow'; import flow from 'rollup-plugin-flow';
import includePaths from 'rollup-plugin-includepaths'; import includePaths from 'rollup-plugin-includepaths';
import copy from 'rollup-plugin-copy';
let includePathOptions = { let includePathOptions = {
include: {}, include: {},
paths: ['src'], paths: ['src'],
external: [], external: [],
extensions: ['.js'] extensions: ['.js'],
}; };
export default { export default {
input: 'src/index.js', input: 'src/index.js',
output: { output: {
file: 'dist/bundle.es.js', file: 'dist/bundle.es.js',
format: 'cjs' format: 'cjs',
}, },
plugins: [ plugins: [
flow({ all: true }), flow({ all: true }),
@ -22,5 +23,6 @@ export default {
babelrc: false, babelrc: false,
presets: ['stage-2'], presets: ['stage-2'],
}), }),
copy({ targets: ['flow-typed'] }),
], ],
} };

View file

@ -68,8 +68,6 @@ export const RESOLVE_URIS_STARTED = 'RESOLVE_URIS_STARTED';
export const RESOLVE_URIS_COMPLETED = 'RESOLVE_URIS_COMPLETED'; export const RESOLVE_URIS_COMPLETED = 'RESOLVE_URIS_COMPLETED';
export const FETCH_CHANNEL_CLAIMS_STARTED = 'FETCH_CHANNEL_CLAIMS_STARTED'; export const FETCH_CHANNEL_CLAIMS_STARTED = 'FETCH_CHANNEL_CLAIMS_STARTED';
export const FETCH_CHANNEL_CLAIMS_COMPLETED = 'FETCH_CHANNEL_CLAIMS_COMPLETED'; export const FETCH_CHANNEL_CLAIMS_COMPLETED = 'FETCH_CHANNEL_CLAIMS_COMPLETED';
export const FETCH_CHANNEL_CLAIM_COUNT_STARTED = 'FETCH_CHANNEL_CLAIM_COUNT_STARTED';
export const FETCH_CHANNEL_CLAIM_COUNT_COMPLETED = 'FETCH_CHANNEL_CLAIM_COUNT_COMPLETED';
export const FETCH_CLAIM_LIST_MINE_STARTED = 'FETCH_CLAIM_LIST_MINE_STARTED'; export const FETCH_CLAIM_LIST_MINE_STARTED = 'FETCH_CLAIM_LIST_MINE_STARTED';
export const FETCH_CLAIM_LIST_MINE_COMPLETED = 'FETCH_CLAIM_LIST_MINE_COMPLETED'; export const FETCH_CLAIM_LIST_MINE_COMPLETED = 'FETCH_CLAIM_LIST_MINE_COMPLETED';
export const ABANDON_CLAIM_STARTED = 'ABANDON_CLAIM_STARTED'; export const ABANDON_CLAIM_STARTED = 'ABANDON_CLAIM_STARTED';
@ -78,6 +76,7 @@ export const FETCH_CHANNEL_LIST_STARTED = 'FETCH_CHANNEL_LIST_STARTED';
export const FETCH_CHANNEL_LIST_COMPLETED = 'FETCH_CHANNEL_LIST_COMPLETED'; export const FETCH_CHANNEL_LIST_COMPLETED = 'FETCH_CHANNEL_LIST_COMPLETED';
export const CREATE_CHANNEL_STARTED = 'CREATE_CHANNEL_STARTED'; export const CREATE_CHANNEL_STARTED = 'CREATE_CHANNEL_STARTED';
export const CREATE_CHANNEL_COMPLETED = 'CREATE_CHANNEL_COMPLETED'; export const CREATE_CHANNEL_COMPLETED = 'CREATE_CHANNEL_COMPLETED';
export const CREATE_CHANNEL_FAILED = 'CREATE_CHANNEL_FAILED';
export const PUBLISH_STARTED = 'PUBLISH_STARTED'; export const PUBLISH_STARTED = 'PUBLISH_STARTED';
export const PUBLISH_COMPLETED = 'PUBLISH_COMPLETED'; export const PUBLISH_COMPLETED = 'PUBLISH_COMPLETED';
export const PUBLISH_FAILED = 'PUBLISH_FAILED'; export const PUBLISH_FAILED = 'PUBLISH_FAILED';

View file

@ -5,13 +5,9 @@ import * as TRANSACTIONS from 'constants/transaction_types';
import * as SORT_OPTIONS from 'constants/sort_options'; import * as SORT_OPTIONS from 'constants/sort_options';
import * as PAGES from 'constants/pages'; import * as PAGES from 'constants/pages';
import { SEARCH_TYPES, SEARCH_OPTIONS } from 'constants/search'; import { SEARCH_TYPES, SEARCH_OPTIONS } from 'constants/search';
import Lbry from 'lbry'; import Lbry from 'lbry';
import { selectState as selectSearchState } from 'redux/selectors/search'; import { selectState as selectSearchState } from 'redux/selectors/search';
// types
// export { Toast } from 'types/Notification';
// constants // constants
export { export {
ACTIONS, ACTIONS,
@ -43,11 +39,12 @@ export { doToast, doDismissToast, doError, doDismissError } from 'redux/actions/
export { export {
doFetchClaimsByChannel, doFetchClaimsByChannel,
doFetchClaimCountByChannel,
doFetchClaimListMine, doFetchClaimListMine,
doAbandonClaim, doAbandonClaim,
doResolveUris, doResolveUris,
doResolveUri, doResolveUri,
doFetchChannelListMine,
doCreateChannel,
} from 'redux/actions/claims'; } from 'redux/actions/claims';
export { export {
@ -146,6 +143,7 @@ export {
selectPlayingUri, selectPlayingUri,
selectChannelClaimCounts, selectChannelClaimCounts,
selectCurrentChannelPage, selectCurrentChannelPage,
makeSelectThumbnailForUri,
} from 'redux/selectors/claims'; } from 'redux/selectors/claims';
export { export {

View file

@ -2,11 +2,121 @@
import 'proxy-polyfill'; import 'proxy-polyfill';
const CHECK_DAEMON_STARTED_TRY_NUMBER = 200; const CHECK_DAEMON_STARTED_TRY_NUMBER = 200;
//
// Basic LBRY sdk connection config
// Offers a proxy to call LBRY sdk methods
const Lbry = { //
const Lbry: LbryTypes = {
isConnected: false, isConnected: false,
connectPromise: null,
daemonConnectionString: 'http://localhost:5279', daemonConnectionString: 'http://localhost:5279',
pendingPublishTimeout: 20 * 60 * 1000,
// Allow overriding daemon connection string (e.g. to `/api/proxy` for lbryweb)
setDaemonConnectionString: (value: string) => {
Lbry.daemonConnectionString = value;
},
// Allow overriding Lbry methods
overrides: {},
setOverride: (methodName, newMethod) => {
Lbry.overrides[methodName] = newMethod;
},
// Returns a human readable media type based on the content type or extension of a file that is returned by the sdk
getMediaType: (contentType: string, extname: ?string) => {
if (extname) {
const formats = [
[/^(mp4|m4v|webm|flv|f4v|ogv)$/i, 'video'],
[/^(mp3|m4a|aac|wav|flac|ogg|opus)$/i, 'audio'],
[/^(html|htm|xml|pdf|odf|doc|docx|md|markdown|txt|epub|org)$/i, 'document'],
[/^(stl|obj|fbx|gcode)$/i, '3D-file'],
];
const res = formats.reduce((ret, testpair) => {
switch (testpair[0].test(ret)) {
case true:
return testpair[1];
default:
return ret;
}
}, extname);
return res === extname ? 'unknown' : res;
} else if (contentType) {
// $FlowFixMe
return /^[^/]+/.exec(contentType)[0];
}
return 'unknown';
},
//
// Lbry SDK Methods
// https://lbry.tech/api/sdk
//
status: (params = {}) => daemonCallWithResult('status', params),
stop: () => daemonCallWithResult('stop', {}),
version: () => daemonCallWithResult('version', {}),
// Claim fetching and manipulation
resolve: params => daemonCallWithResult('resolve', params),
get: params => daemonCallWithResult('get', params),
publish: params => daemonCallWithResult('publish', params),
claim_search: params => daemonCallWithResult('claim_search', params),
claim_list: params => daemonCallWithResult('claim_list', params),
channel_create: params => daemonCallWithResult('channel_create', params),
channel_list: params => daemonCallWithResult('channel_list', params),
stream_abandon: params => daemonCallWithResult('stream_abandon', params),
channel_abandon: params => daemonCallWithResult('channel_abandon', params),
support_create: params => daemonCallWithResult('support_create', params),
// File fetching and manipulation
file_list: (params = {}) => daemonCallWithResult('file_list', params),
file_delete: (params = {}) => daemonCallWithResult('file_delete', params),
file_set_status: (params = {}) => daemonCallWithResult('file_set_status', params),
blob_delete: (params = {}) => daemonCallWithResult('blob_delete', params),
blob_list: (params = {}) => daemonCallWithResult('blob_list', params),
// Wallet utilities
account_balance: (params = {}) => daemonCallWithResult('account_balance', params),
account_decrypt: () => daemonCallWithResult('account_decrypt', {}),
account_encrypt: (params = {}) => daemonCallWithResult('account_encrypt', params),
account_unlock: (params = {}) => daemonCallWithResult('account_unlock', params),
account_list: (params = {}) => daemonCallWithResult('account_list', params),
account_send: (params = {}) => daemonCallWithResult('account_send', params),
address_is_mine: (params = {}) => daemonCallWithResult('address_is_mine', params),
address_unused: (params = {}) => daemonCallWithResult('address_unused', params),
transaction_list: (params = {}) => daemonCallWithResult('transaction_list', params),
utxo_release: (params = {}) => daemonCallWithResult('utxo_release', params),
sync_hash: (params = {}) => daemonCallWithResult('sync_hash', params),
sync_apply: (params = {}) => daemonCallWithResult('sync_apply', params),
// Connect to the sdk
connect: () => {
if (Lbry.connectPromise === null) {
Lbry.connectPromise = new Promise((resolve, reject) => {
let tryNum = 0;
// Check every half second to see if the daemon is accepting connections
function checkDaemonStarted() {
tryNum += 1;
Lbry.status()
.then(resolve)
.catch(() => {
if (tryNum <= CHECK_DAEMON_STARTED_TRY_NUMBER) {
setTimeout(checkDaemonStarted, tryNum < 50 ? 400 : 1000);
} else {
reject(new Error('Unable to connect to LBRY'));
}
});
}
checkDaemonStarted();
});
}
// Flow thinks this could be empty, but it will always reuturn a promise
// $FlowFixMe
return Lbry.connectPromise;
},
}; };
function checkAndParse(response) { function checkAndParse(response) {
@ -50,8 +160,8 @@ function apiCall(method: string, params: ?{}, resolve: Function, reject: Functio
.catch(reject); .catch(reject);
} }
const daemonCallWithResult = (name, params = {}) => function daemonCallWithResult(name: string, params: ?{} = {}) {
new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
apiCall( apiCall(
name, name,
params, params,
@ -61,170 +171,12 @@ const daemonCallWithResult = (name, params = {}) =>
reject reject
); );
}); });
// blobs
Lbry.blob_delete = (params = {}) => daemonCallWithResult('blob_delete', params);
Lbry.blob_list = (params = {}) => daemonCallWithResult('blob_list', params);
// core
Lbry.status = (params = {}) => daemonCallWithResult('status', params);
Lbry.version = () => daemonCallWithResult('version', {});
Lbry.file_delete = (params = {}) => daemonCallWithResult('file_delete', params);
Lbry.file_set_status = (params = {}) => daemonCallWithResult('file_set_status', params);
Lbry.stop = () => daemonCallWithResult('stop', {});
// claims
Lbry.claim_list_by_channel = (params = {}) => daemonCallWithResult('claim_list_by_channel', params);
// wallet
Lbry.account_balance = (params = {}) => daemonCallWithResult('account_balance', params);
Lbry.account_decrypt = () => daemonCallWithResult('account_decrypt', {});
Lbry.account_encrypt = (params = {}) => daemonCallWithResult('account_encrypt', params);
Lbry.account_list = (params = {}) => daemonCallWithResult('account_list', params);
Lbry.address_is_mine = (params = {}) => daemonCallWithResult('address_is_mine', params);
Lbry.wallet_lock = () => daemonCallWithResult('wallet_lock', {});
Lbry.address_unused = (params = {}) => daemonCallWithResult('address_unused', params);
Lbry.wallet_send = (params = {}) => daemonCallWithResult('wallet_send', params);
Lbry.account_unlock = (params = {}) => daemonCallWithResult('account_unlock', params);
Lbry.address_unused = () => daemonCallWithResult('address_unused', {});
Lbry.claim_tip = (params = {}) => daemonCallWithResult('claim_tip', params);
// transactions
Lbry.transaction_list = (params = {}) => daemonCallWithResult('transaction_list', params);
Lbry.utxo_release = (params = {}) => daemonCallWithResult('utxo_release', params);
// sync
Lbry.sync_hash = (params = {}) => daemonCallWithResult('sync_hash', params);
Lbry.sync_apply = (params = {}) => daemonCallWithResult('sync_apply', params);
Lbry.connectPromise = null;
Lbry.connect = () => {
if (Lbry.connectPromise === null) {
Lbry.connectPromise = new Promise((resolve, reject) => {
let tryNum = 0;
// Check every half second to see if the daemon is accepting connections
function checkDaemonStarted() {
tryNum += 1;
Lbry.status()
.then(resolve)
.catch(() => {
if (tryNum <= CHECK_DAEMON_STARTED_TRY_NUMBER) {
setTimeout(checkDaemonStarted, tryNum < 50 ? 400 : 1000);
} else {
reject(new Error('Unable to connect to LBRY'));
}
});
} }
checkDaemonStarted(); // This is only for a fallback
}); // If there is a Lbry method that is being called by an app, it should be added to /flow-typed/Lbry.js
}
return Lbry.connectPromise;
};
Lbry.getMediaType = (contentType, extname) => {
if (extname) {
const formats = [
[/^(mp4|m4v|webm|flv|f4v|ogv)$/i, 'video'],
[/^(mp3|m4a|aac|wav|flac|ogg|opus)$/i, 'audio'],
[/^(html|htm|xml|pdf|odf|doc|docx|md|markdown|txt|epub|org)$/i, 'document'],
[/^(stl|obj|fbx|gcode)$/i, '3D-file'],
];
const res = formats.reduce((ret, testpair) => {
switch (testpair[0].test(ret)) {
case true:
return testpair[1];
default:
return ret;
}
}, extname);
return res === extname ? 'unknown' : res;
} else if (contentType) {
return /^[^/]+/.exec(contentType)[0];
}
return 'unknown';
};
/**
* Wrappers for API methods to simulate missing or future behavior. Unlike the old-style stubs,
* these are designed to be transparent wrappers around the corresponding API methods.
*/
/**
* Returns results from the file_list API method, plus dummy entries for pending publishes.
* (If a real publish with the same name is found, the pending publish will be ignored and removed.)
*/
Lbry.file_list = (params = {}) =>
new Promise((resolve, reject) => {
apiCall(
'file_list',
params,
fileInfos => {
resolve(fileInfos);
},
reject
);
});
Lbry.claim_list_mine = (params = {}) =>
new Promise((resolve, reject) => {
apiCall(
'claim_list_mine',
params,
claims => {
resolve(claims);
},
reject
);
});
Lbry.get = (params = {}) =>
new Promise((resolve, reject) => {
apiCall(
'get',
params,
streamInfo => {
resolve(streamInfo);
},
reject
);
});
Lbry.resolve = (params = {}) =>
new Promise((resolve, reject) => {
apiCall(
'resolve',
params,
data => {
resolve(data || {});
},
reject
);
});
Lbry.publish = (params = {}) =>
new Promise((resolve, reject) => {
if (Lbry.overrides.publish) {
Lbry.overrides.publish(params).then(resolve, reject);
} else {
apiCall('publish', params, resolve, reject);
}
});
// Allow overriding Lbry methods
Lbry.overrides = {};
Lbry.setOverride = (methodName, newMethod) => {
Lbry.overrides[methodName] = newMethod;
};
// Allow overriding daemon connection string (e.g. to `/api/proxy` for lbryweb)
Lbry.setDaemonConnectionString = value => {
Lbry.daemonConnectionString = value;
};
const lbryProxy = new Proxy(Lbry, { const lbryProxy = new Proxy(Lbry, {
get(target, name) { get(target: LbryTypes, name: string) {
if (name in target) { if (name in target) {
return target[name]; return target[name];
} }

View file

@ -1,12 +1,14 @@
// @flow
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
import Lbry from 'lbry'; import Lbry from 'lbry';
import { normalizeURI } from 'lbryURI'; import { normalizeURI } from 'lbryURI';
import { doToast } from 'redux/actions/notifications'; import { doToast } from 'redux/actions/notifications';
import { selectMyClaimsRaw, selectResolvingUris, selectClaimsByUri } from 'redux/selectors/claims'; import { selectMyClaimsRaw, selectResolvingUris, selectClaimsByUri } from 'redux/selectors/claims';
import { doFetchTransactions } from 'redux/actions/wallet'; import { doFetchTransactions } from 'redux/actions/wallet';
import { creditsToString } from 'util/formatCredits';
export function doResolveUris(uris, returnCachedClaims = false) { export function doResolveUris(uris: Array<string>, returnCachedClaims: boolean = false) {
return (dispatch, getState) => { return (dispatch: Dispatch, getState: GetState) => {
const normalizedUris = uris.map(normalizeURI); const normalizedUris = uris.map(normalizeURI);
const state = getState(); const state = getState();
@ -29,8 +31,15 @@ export function doResolveUris(uris, returnCachedClaims = false) {
data: { uris: normalizedUris }, data: { uris: normalizedUris },
}); });
const resolveInfo = {}; const resolveInfo: {
Lbry.resolve({ urls: urisToResolve }).then(result => { [string]: {
claim: ?StreamClaim,
certificate: ?ChannelClaim,
claimsInChannel: ?number,
},
} = {};
Lbry.resolve({ urls: urisToResolve }).then((result: ResolveResponse) => {
Object.entries(result).forEach(([uri, uriResolveInfo]) => { Object.entries(result).forEach(([uri, uriResolveInfo]) => {
const fallbackResolveInfo = { const fallbackResolveInfo = {
claim: null, claim: null,
@ -38,10 +47,16 @@ export function doResolveUris(uris, returnCachedClaims = false) {
certificate: null, certificate: null,
}; };
const { claim, certificate, claims_in_channel: claimsInChannel } = // Flow has terrible Object.entries support
uriResolveInfo && !uriResolveInfo.error ? uriResolveInfo : fallbackResolveInfo; // https://github.com/facebook/flow/issues/2221
// $FlowFixMe
if (uriResolveInfo.error) {
resolveInfo[uri] = { ...fallbackResolveInfo };
} else {
// $FlowFixMe
const { claim, certificate, claims_in_channel: claimsInChannel } = uriResolveInfo;
resolveInfo[uri] = { claim, certificate, claimsInChannel }; resolveInfo[uri] = { claim, certificate, claimsInChannel };
}
}); });
dispatch({ dispatch({
@ -52,17 +67,17 @@ export function doResolveUris(uris, returnCachedClaims = false) {
}; };
} }
export function doResolveUri(uri) { export function doResolveUri(uri: string) {
return doResolveUris([uri]); return doResolveUris([uri]);
} }
export function doFetchClaimListMine() { export function doFetchClaimListMine() {
return dispatch => { return (dispatch: Dispatch) => {
dispatch({ dispatch({
type: ACTIONS.FETCH_CLAIM_LIST_MINE_STARTED, type: ACTIONS.FETCH_CLAIM_LIST_MINE_STARTED,
}); });
Lbry.claim_list_mine().then(claims => { Lbry.claim_list().then((claims: ClaimListResponse) => {
dispatch({ dispatch({
type: ACTIONS.FETCH_CLAIM_LIST_MINE_COMPLETED, type: ACTIONS.FETCH_CLAIM_LIST_MINE_COMPLETED,
data: { data: {
@ -73,13 +88,18 @@ export function doFetchClaimListMine() {
}; };
} }
export function doAbandonClaim(txid, nout) { export function doAbandonClaim(txid: string, nout: number) {
return (dispatch, getState) => { return (dispatch: Dispatch, getState: GetState) => {
const state = getState(); const state = getState();
const myClaims = selectMyClaimsRaw(state); const myClaims: Array<ChannelClaim | StreamClaim> = selectMyClaimsRaw(state);
const { claim_id: claimId } = myClaims.find( const claimToAbandon = myClaims.find(claim => claim.txid === txid && claim.nout === nout);
claim => claim.txid === txid && claim.nout === nout
); if (!claimToAbandon) {
console.error('No associated claim with txid: ', txid);
return;
}
const { claim_id: claimId, name: claimName } = claimToAbandon;
dispatch({ dispatch({
type: ACTIONS.ABANDON_CLAIM_STARTED, type: ACTIONS.ABANDON_CLAIM_STARTED,
@ -91,55 +111,51 @@ export function doAbandonClaim(txid, nout) {
const errorCallback = () => { const errorCallback = () => {
dispatch( dispatch(
doToast({ doToast({
message: 'Transaction failed', message: 'Error abandoning claim',
isError: true, isError: true,
}) })
); );
}; };
const successCallback = results => { const successCallback = () => {
if (results.success === true) {
dispatch({ dispatch({
type: ACTIONS.ABANDON_CLAIM_SUCCEEDED, type: ACTIONS.ABANDON_CLAIM_SUCCEEDED,
data: { data: {
claimId, claimId,
}, },
}); });
dispatch( dispatch(
doToast({ doToast({
message: 'Successfully abandoned your claim', message: 'Successfully abandoned your claim',
}) })
); );
// After abandoning, call claim_list_mine to show the claim as abandoned // After abandoning, call claim_list to show the claim as abandoned
// Also fetch transactions to show the new abandon transaction // Also fetch transactions to show the new abandon transaction
dispatch(doFetchClaimListMine()); dispatch(doFetchClaimListMine());
dispatch(doFetchTransactions()); dispatch(doFetchTransactions());
} else {
dispatch(
doToast({
message: 'Error abandoning claim',
isError: true,
})
);
}
}; };
Lbry.claim_abandon({ const abandonParams = {
txid, txid,
nout, nout,
}).then(successCallback, errorCallback); blocking: true,
};
const method = claimName.startsWith('@') ? 'channel_abandon' : 'stream_abandon';
Lbry[method](abandonParams).then(successCallback, errorCallback);
}; };
} }
export function doFetchClaimsByChannel(uri, page) { export function doFetchClaimsByChannel(uri: string, page: number = 1) {
return dispatch => { return (dispatch: Dispatch) => {
dispatch({ dispatch({
type: ACTIONS.FETCH_CHANNEL_CLAIMS_STARTED, type: ACTIONS.FETCH_CHANNEL_CLAIMS_STARTED,
data: { uri, page }, data: { uri, page },
}); });
Lbry.claim_list_by_channel({ uri, page: page || 1 }).then(result => { Lbry.claim_search({ uri, page: page || 1 }).then((result: ClaimSearchResponse) => {
const claimResult = result[uri] || {}; const claimResult = result[uri] || {};
const { claims_in_channel: claimsInChannel, returned_page: returnedPage } = claimResult; const { claims_in_channel: claimsInChannel, returned_page: returnedPage } = claimResult;
@ -155,24 +171,49 @@ export function doFetchClaimsByChannel(uri, page) {
}; };
} }
export function doFetchClaimCountByChannel(uri) { export function doCreateChannel(name: string, amount: number) {
return dispatch => { return (dispatch: Dispatch) => {
dispatch({ dispatch({
type: ACTIONS.FETCH_CHANNEL_CLAIM_COUNT_STARTED, type: ACTIONS.CREATE_CHANNEL_STARTED,
data: { uri },
}); });
Lbry.claim_list_by_channel({ uri }).then(result => { return (
const claimResult = result[uri]; Lbry.channel_create({
const totalClaims = claimResult ? claimResult.claims_in_channel : 0; name,
bid: creditsToString(amount),
})
// outputs[0] is the certificate
// outputs[1] is the change from the tx, not in the app currently
.then((result: ChannelCreateResponse) => {
const channelClaim = result.outputs[0];
dispatch({ dispatch({
type: ACTIONS.FETCH_CHANNEL_CLAIM_COUNT_COMPLETED, type: ACTIONS.CREATE_CHANNEL_COMPLETED,
data: { data: { channelClaim },
uri,
totalClaims,
},
}); });
})
.catch(error => {
dispatch({
type: ACTIONS.CREATE_CHANNEL_FAILED,
data: error,
}); });
})
);
};
}
export function doFetchChannelListMine() {
return (dispatch: Dispatch) => {
dispatch({
type: ACTIONS.FETCH_CHANNEL_LIST_STARTED,
});
const callback = (channels: Array<ChannelClaim>) => {
dispatch({
type: ACTIONS.FETCH_CHANNEL_LIST_COMPLETED,
data: { claims: channels },
});
};
Lbry.channel_list().then(callback);
}; };
} }

View file

@ -1,5 +1,4 @@
// @flow // @flow
import type { ToastParams } from 'types/Notification';
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
import uuid from 'uuid/v4'; import uuid from 'uuid/v4';

View file

@ -1,5 +1,4 @@
// @flow // @flow
import type { SearchState, SearchOptions } from 'types/Search';
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
import { buildURI } from 'lbryURI'; import { buildURI } from 'lbryURI';
import { doResolveUri } from 'redux/actions/claims'; import { doResolveUri } from 'redux/actions/claims';
@ -113,7 +112,7 @@ export const doSearch = (
fetch(`${CONNECTION_STRING}search?${queryWithOptions}`) fetch(`${CONNECTION_STRING}search?${queryWithOptions}`)
.then(handleFetchResponse) .then(handleFetchResponse)
.then(data => { .then((data: Array<{ name: String, claimId: string }>) => {
const uris = []; const uris = [];
const actions = []; const actions = [];

View file

@ -97,7 +97,6 @@ export function doGetNewAddress() {
type: ACTIONS.GET_NEW_ADDRESS_STARTED, type: ACTIONS.GET_NEW_ADDRESS_STARTED,
}); });
// Removed localStorage use, since address is expected to be stored in redux store
Lbry.address_unused().then(address => { Lbry.address_unused().then(address => {
dispatch({ dispatch({
type: ACTIONS.GET_NEW_ADDRESS_COMPLETED, type: ACTIONS.GET_NEW_ADDRESS_COMPLETED,
@ -181,8 +180,8 @@ export function doSendDraftTransaction(address, amount) {
); );
}; };
Lbry.wallet_send({ Lbry.account_send({
address, addresses: [address],
amount: creditsToString(amount), amount: creditsToString(amount),
}).then(successCallback, errorCallback); }).then(successCallback, errorCallback);
}; };
@ -259,9 +258,10 @@ export function doSendTip(amount, claimId, uri, successCallback, errorCallback)
type: ACTIONS.SUPPORT_TRANSACTION_STARTED, type: ACTIONS.SUPPORT_TRANSACTION_STARTED,
}); });
Lbry.claim_tip({ Lbry.support_create({
claim_id: claimId, claim_id: claimId,
amount: creditsToString(amount), amount: creditsToString(amount),
tip: true,
}).then(success, error); }).then(success, error);
}; };
} }

View file

@ -1,40 +1,84 @@
// @flow
// This file has a lot of FlowFixMe comments
// It's due to Flow's support of Object.{values,entries}
// https://github.com/facebook/flow/issues/2221
// We could move to es6 Sets/Maps, but those are not recommended for redux
// https://github.com/reduxjs/redux/issues/1499
// Unsure of the best solution at the momentf
// - Sean
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
import { buildURI } from 'lbryURI'; import { buildURI, parseURI } from 'lbryURI';
const reducers = {}; type State = {
channelClaimCounts: { [string]: number },
const defaultState = { claimsByUri: { [string]: string },
channelClaimCounts: {}, byId: { [string]: StreamClaim | ChannelClaim },
resolvingUris: Array<string>,
pendingById: { [string]: StreamClaim | ChannelClaim },
myChannelClaims: Set<string>,
abandoningById: { [string]: boolean },
fetchingChannelClaims: { [string]: number },
fetchingMyChannels: boolean,
claimsByChannel: {
[string]: {
all: Array<string>,
[number]: Array<string>,
},
},
}; };
reducers[ACTIONS.RESOLVE_URIS_COMPLETED] = (state, action) => { const reducers = {};
const { resolveInfo } = action.data; const defaultState = {
byId: {},
claimsByUri: {},
claimsByChannel: {},
channelClaimCounts: {},
fetchingChannelClaims: {},
resolvingUris: [],
// This should not be a Set
// Storing sets in reducers can cause issues
myChannelClaims: new Set(),
fetchingMyChannels: false,
abandoningById: {},
pendingById: {},
};
reducers[ACTIONS.RESOLVE_URIS_COMPLETED] = (state: State, action: any): State => {
const { resolveInfo }: { [string]: ClaimWithPossibleCertificate } = action.data;
const byUri = Object.assign({}, state.claimsByUri); const byUri = Object.assign({}, state.claimsByUri);
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
const channelClaimCounts = Object.assign({}, state.channelClaimCounts); const channelClaimCounts = Object.assign({}, state.channelClaimCounts);
Object.entries(resolveInfo).forEach(([uri, { certificate, claimsInChannel }]) => { Object.entries(resolveInfo).forEach(
if (certificate && !Number.isNaN(claimsInChannel)) { ([uri: string, resolveResponse: ClaimWithPossibleCertificate]) => {
channelClaimCounts[uri] = claimsInChannel; // $FlowFixMe
if (resolveResponse.certificate && !Number.isNaN(resolveResponse.claimsInChannel)) {
// $FlowFixMe
channelClaimCounts[uri] = resolveResponse.claimsInChannel;
} }
}); }
);
// $FlowFixMe
Object.entries(resolveInfo).forEach(([uri, { certificate, claim }]) => { Object.entries(resolveInfo).forEach(([uri, { certificate, claim }]) => {
if (claim) { if (claim && !certificate) {
byId[claim.claim_id] = claim; byId[claim.claim_id] = claim;
byUri[uri] = claim.claim_id; byUri[uri] = claim.claim_id;
} else if (claim === undefined && certificate !== undefined) { } else if (claim && certificate) {
byId[claim.claim_id] = claim;
byUri[uri] = claim.claim_id;
byId[certificate.claim_id] = certificate;
const channelUri = `lbry://${certificate.name}#${certificate.claim_id}`;
byUri[channelUri] = certificate.claim_id;
} else if (!claim && certificate) {
byId[certificate.claim_id] = certificate; byId[certificate.claim_id] = certificate;
// Don't point URI at the channel certificate unless it actually is
// a channel URI. This is brittle.
if (!uri.split(certificate.name)[1].match(/\//)) {
byUri[uri] = certificate.claim_id; byUri[uri] = certificate.claim_id;
} else { } else {
byUri[uri] = null; byUri[uri] = null;
} }
} else {
byUri[uri] = null;
}
}); });
return Object.assign({}, state, { return Object.assign({}, state, {
@ -45,18 +89,21 @@ reducers[ACTIONS.RESOLVE_URIS_COMPLETED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.FETCH_CLAIM_LIST_MINE_STARTED] = state => reducers[ACTIONS.FETCH_CLAIM_LIST_MINE_STARTED] = (state: State): State =>
Object.assign({}, state, { Object.assign({}, state, {
isFetchingClaimListMine: true, isFetchingClaimListMine: true,
}); });
reducers[ACTIONS.FETCH_CLAIM_LIST_MINE_COMPLETED] = (state, action) => { reducers[ACTIONS.FETCH_CLAIM_LIST_MINE_COMPLETED] = (state: State, action: any): State => {
const { claims } = action.data; const { claims }: { claims: Array<StreamClaim | ChannelClaim> } = action.data;
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
const byUri = Object.assign({}, state.claimsByUri); const byUri = Object.assign({}, state.claimsByUri);
const pendingById = Object.assign({}, state.pendingById); const pendingById: { [string]: StreamClaim | ChannelClaim } = Object.assign(
{},
state.pendingById
);
claims.forEach(claim => { claims.forEach((claim: StreamClaim | ChannelClaim) => {
const uri = buildURI({ claimName: claim.name, claimId: claim.claim_id }); const uri = buildURI({ claimName: claim.name, claimId: claim.claim_id });
if (claim.type && claim.type.match(/claim|update/)) { if (claim.type && claim.type.match(/claim|update/)) {
@ -73,8 +120,10 @@ reducers[ACTIONS.FETCH_CLAIM_LIST_MINE_COMPLETED] = (state, action) => {
// Remove old pending publishes // Remove old pending publishes
Object.values(pendingById) Object.values(pendingById)
// $FlowFixMe
.filter(pendingClaim => byId[pendingClaim.claim_id]) .filter(pendingClaim => byId[pendingClaim.claim_id])
.forEach(pendingClaim => { .forEach(pendingClaim => {
// $FlowFixMe
delete pendingById[pendingClaim.claim_id]; delete pendingById[pendingClaim.claim_id];
}); });
@ -87,11 +136,11 @@ reducers[ACTIONS.FETCH_CLAIM_LIST_MINE_COMPLETED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.FETCH_CHANNEL_LIST_STARTED] = state => reducers[ACTIONS.FETCH_CHANNEL_LIST_STARTED] = (state: State): State =>
Object.assign({}, state, { fetchingMyChannels: true }); Object.assign({}, state, { fetchingMyChannels: true });
reducers[ACTIONS.FETCH_CHANNEL_LIST_COMPLETED] = (state, action) => { reducers[ACTIONS.FETCH_CHANNEL_LIST_COMPLETED] = (state: State, action: any): State => {
const { claims } = action.data; const { claims }: { claims: Array<ChannelClaim> } = action.data;
const myChannelClaims = new Set(state.myChannelClaims); const myChannelClaims = new Set(state.myChannelClaims);
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
@ -107,7 +156,7 @@ reducers[ACTIONS.FETCH_CHANNEL_LIST_COMPLETED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.FETCH_CHANNEL_CLAIMS_STARTED] = (state, action) => { reducers[ACTIONS.FETCH_CHANNEL_CLAIMS_STARTED] = (state: State, action: any): State => {
const { uri, page } = action.data; const { uri, page } = action.data;
const fetchingChannelClaims = Object.assign({}, state.fetchingChannelClaims); const fetchingChannelClaims = Object.assign({}, state.fetchingChannelClaims);
@ -119,8 +168,12 @@ reducers[ACTIONS.FETCH_CHANNEL_CLAIMS_STARTED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.FETCH_CHANNEL_CLAIMS_COMPLETED] = (state, action) => { reducers[ACTIONS.FETCH_CHANNEL_CLAIMS_COMPLETED] = (state: State, action: any): State => {
const { uri, claims, page } = action.data; const {
uri,
claims,
page,
}: { uri: string, claims: Array<StreamClaim>, page: number } = action.data;
const claimsByChannel = Object.assign({}, state.claimsByChannel); const claimsByChannel = Object.assign({}, state.claimsByChannel);
const byChannel = Object.assign({}, claimsByChannel[uri]); const byChannel = Object.assign({}, claimsByChannel[uri]);
@ -153,8 +206,8 @@ reducers[ACTIONS.FETCH_CHANNEL_CLAIMS_COMPLETED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.ABANDON_CLAIM_STARTED] = (state, action) => { reducers[ACTIONS.ABANDON_CLAIM_STARTED] = (state: State, action: any): State => {
const { claimId } = action.data; const { claimId }: { claimId: string } = action.data;
const abandoningById = Object.assign({}, state.abandoningById); const abandoningById = Object.assign({}, state.abandoningById);
abandoningById[claimId] = true; abandoningById[claimId] = true;
@ -164,8 +217,8 @@ reducers[ACTIONS.ABANDON_CLAIM_STARTED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.ABANDON_CLAIM_SUCCEEDED] = (state, action) => { reducers[ACTIONS.ABANDON_CLAIM_SUCCEEDED] = (state: State, action: any): State => {
const { claimId } = action.data; const { claimId }: { claimId: string } = action.data;
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
const claimsByUri = Object.assign({}, state.claimsByUri); const claimsByUri = Object.assign({}, state.claimsByUri);
@ -183,8 +236,8 @@ reducers[ACTIONS.ABANDON_CLAIM_SUCCEEDED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.CREATE_CHANNEL_COMPLETED] = (state, action) => { reducers[ACTIONS.CREATE_CHANNEL_COMPLETED] = (state: State, action: any): State => {
const { channelClaim } = action.data; const channelClaim: ChannelClaim = action.data.channelClaim;
const byId = Object.assign({}, state.byId); const byId = Object.assign({}, state.byId);
const myChannelClaims = new Set(state.myChannelClaims); const myChannelClaims = new Set(state.myChannelClaims);
@ -197,11 +250,11 @@ reducers[ACTIONS.CREATE_CHANNEL_COMPLETED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.RESOLVE_URIS_STARTED] = (state, action) => { reducers[ACTIONS.RESOLVE_URIS_STARTED] = (state: State, action: any): State => {
const { uris } = action.data; const { uris }: { uris: Array<string> } = action.data;
const oldResolving = state.resolvingUris || []; const oldResolving = state.resolvingUris || [];
const newResolving = Object.assign([], oldResolving); const newResolving = oldResolving.slice();
uris.forEach(uri => { uris.forEach(uri => {
if (!newResolving.includes(uri)) { if (!newResolving.includes(uri)) {
@ -214,18 +267,7 @@ reducers[ACTIONS.RESOLVE_URIS_STARTED] = (state, action) => {
}); });
}; };
reducers[ACTIONS.FETCH_CHANNEL_CLAIM_COUNT_COMPLETED] = (state, action) => { export function claimsReducer(state: State = defaultState, action: any) {
const channelClaimCounts = Object.assign({}, state.channelClaimCounts);
const { uri, totalClaims } = action.data;
channelClaimCounts[uri] = totalClaims;
return Object.assign({}, state, {
channelClaimCounts,
});
};
export function claimsReducer(state = defaultState, action) {
const handler = reducers[action.type]; const handler = reducers[action.type];
if (handler) return handler(state, action); if (handler) return handler(state, action);
return state; return state;

View file

@ -1,12 +1,4 @@
// @flow // @flow
import type {
NotificationState,
DoToast,
DoError,
DoNotification,
DoEditNotification,
DoDeleteNotification,
} from 'types/Notification';
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
import { handleActions } from 'util/redux-utils'; import { handleActions } from 'util/redux-utils';
@ -20,8 +12,8 @@ const notificationsReducer = handleActions(
{ {
// Toasts // Toasts
[ACTIONS.CREATE_TOAST]: (state: NotificationState, action: DoToast) => { [ACTIONS.CREATE_TOAST]: (state: NotificationState, action: DoToast) => {
const toast = action.data; const toast: Toast = action.data;
const newToasts = state.toasts.slice(); const newToasts: Array<Toast> = state.toasts.slice();
newToasts.push(toast); newToasts.push(toast);
return { return {
@ -30,7 +22,7 @@ const notificationsReducer = handleActions(
}; };
}, },
[ACTIONS.DISMISS_TOAST]: (state: NotificationState) => { [ACTIONS.DISMISS_TOAST]: (state: NotificationState) => {
const newToasts = state.toasts.slice(); const newToasts: Array<Toast> = state.toasts.slice();
newToasts.shift(); newToasts.shift();
return { return {
@ -41,8 +33,8 @@ const notificationsReducer = handleActions(
// Notifications // Notifications
[ACTIONS.CREATE_NOTIFICATION]: (state: NotificationState, action: DoNotification) => { [ACTIONS.CREATE_NOTIFICATION]: (state: NotificationState, action: DoNotification) => {
const notification = action.data; const notification: Notification = action.data;
const newNotifications = state.notifications.slice(); const newNotifications: Array<Notification> = state.notifications.slice();
newNotifications.push(notification); newNotifications.push(notification);
return { return {
@ -53,10 +45,9 @@ const notificationsReducer = handleActions(
// Used to mark notifications as read/dismissed // Used to mark notifications as read/dismissed
[ACTIONS.EDIT_NOTIFICATION]: (state: NotificationState, action: DoEditNotification) => { [ACTIONS.EDIT_NOTIFICATION]: (state: NotificationState, action: DoEditNotification) => {
const { notification } = action.data; const { notification } = action.data;
let notifications = state.notifications.slice(); let notifications: Array<Notification> = state.notifications.slice();
notifications = notifications.map( notifications = notifications.map(pastNotification =>
pastNotification =>
pastNotification.id === notification.id ? notification : pastNotification pastNotification.id === notification.id ? notification : pastNotification
); );
@ -67,7 +58,7 @@ const notificationsReducer = handleActions(
}, },
[ACTIONS.DELETE_NOTIFICATION]: (state: NotificationState, action: DoDeleteNotification) => { [ACTIONS.DELETE_NOTIFICATION]: (state: NotificationState, action: DoDeleteNotification) => {
const { id } = action.data; const { id } = action.data;
let newNotifications = state.notifications.slice(); let newNotifications: Array<Notification> = state.notifications.slice();
newNotifications = newNotifications.filter(notification => notification.id !== id); newNotifications = newNotifications.filter(notification => notification.id !== id);
return { return {
@ -78,8 +69,8 @@ const notificationsReducer = handleActions(
// Errors // Errors
[ACTIONS.CREATE_ERROR]: (state: NotificationState, action: DoError) => { [ACTIONS.CREATE_ERROR]: (state: NotificationState, action: DoError) => {
const error = action.data; const error: ErrorNotification = action.data;
const newErrors = state.errors.slice(); const newErrors: Array<ErrorNotification> = state.errors.slice();
newErrors.push(error); newErrors.push(error);
return { return {
@ -88,7 +79,7 @@ const notificationsReducer = handleActions(
}; };
}, },
[ACTIONS.DISMISS_ERROR]: (state: NotificationState) => { [ACTIONS.DISMISS_ERROR]: (state: NotificationState) => {
const newErrors = state.errors.slice(); const newErrors: Array<ErrorNotification> = state.errors.slice();
newErrors.shift(); newErrors.shift();
return { return {

View file

@ -2,14 +2,6 @@
import * as ACTIONS from 'constants/action_types'; import * as ACTIONS from 'constants/action_types';
import { handleActions } from 'util/redux-utils'; import { handleActions } from 'util/redux-utils';
import { SEARCH_OPTIONS } from 'constants/search'; import { SEARCH_OPTIONS } from 'constants/search';
import type {
SearchState,
SearchSuccess,
UpdateSearchQuery,
UpdateSearchSuggestions,
HistoryNavigate,
UpdateSearchOptions,
} from 'types/Search';
const defaultState = { const defaultState = {
isActive: false, // does the user have any typed text in the search input isActive: false, // does the user have any typed text in the search input
@ -69,17 +61,6 @@ export const searchReducer = handleActions(
}, },
}), }),
// clear the searchQuery on back/forward unless to search page
[ACTIONS.HISTORY_NAVIGATE]: (state: SearchState, action: HistoryNavigate): SearchState => {
const { url } = action.data;
return {
...state,
searchQuery: url.indexOf('/search') === 0 ? url.slice(14) : '',
isActive: url.indexOf('/search') === 0,
suggestions: {},
};
},
// sets isActive to false so the uri will be populated correctly if the // sets isActive to false so the uri will be populated correctly if the
// user is on a file page. The search query will still be present on any // user is on a file page. The search query will still be present on any
// other page // other page

View file

@ -284,7 +284,7 @@ reducers[ACTIONS.WALLET_LOCK_FAILED] = (state: WalletState, action: ActionResult
walletLockResult: action.result, walletLockResult: action.result,
}); });
reducers[ACTIONS.SET_TRANSACTION_LIST_FILTER] = (state: WalletState, action: {}) => reducers[ACTIONS.SET_TRANSACTION_LIST_FILTER] = (state: WalletState, action: { data: string }) =>
Object.assign({}, state, { Object.assign({}, state, {
transactionListFilter: action.data, transactionListFilter: action.data,
}); });

View file

@ -1,3 +1,4 @@
// @flow
import { normalizeURI, buildURI, parseURI } from 'lbryURI'; import { normalizeURI, buildURI, parseURI } from 'lbryURI';
import { selectSearchUrisByQuery } from 'redux/selectors/search'; import { selectSearchUrisByQuery } from 'redux/selectors/search';
import { createSelector } from 'reselect'; import { createSelector } from 'reselect';
@ -6,14 +7,20 @@ import { getSearchQueryString } from 'util/query_params';
const selectState = state => state.claims || {}; const selectState = state => state.claims || {};
export const selectClaimsById = createSelector(selectState, state => state.byId || {}); export const selectClaimsById = createSelector(
selectState,
state => state.byId || {}
);
export const selectCurrentChannelPage = createSelector( export const selectCurrentChannelPage = createSelector(
selectState, selectState,
state => state.currentChannelPage || 1 state => state.currentChannelPage || 1
); );
export const selectClaimsByUri = createSelector(selectState, selectClaimsById, (state, byId) => { export const selectClaimsByUri = createSelector(
selectState,
selectClaimsById,
(state, byId) => {
const byUri = state.claimsByUri || {}; const byUri = state.claimsByUri || {};
const claims = {}; const claims = {};
@ -31,33 +38,47 @@ export const selectClaimsByUri = createSelector(selectState, selectClaimsById, (
}); });
return claims; return claims;
}); }
);
export const selectAllClaimsByChannel = createSelector( export const selectAllClaimsByChannel = createSelector(
selectState, selectState,
state => state.claimsByChannel || {} state => state.claimsByChannel || {}
); );
export const selectPendingById = createSelector(selectState, state => state.pendingById || {}); export const selectPendingById = createSelector(
selectState,
export const selectPendingClaims = createSelector(selectState, state => state => state.pendingById || {}
Object.values(state.pendingById || [])
); );
export const makeSelectClaimIsPending = uri => export const selectPendingClaims = createSelector(
createSelector(selectPendingById, pendingById => { selectState,
state => Object.values(state.pendingById || [])
);
export const makeSelectClaimIsPending = (uri: string) =>
createSelector(
selectPendingById,
pendingById => {
const { claimId } = parseURI(uri); const { claimId } = parseURI(uri);
return Boolean(pendingById[claimId]); return Boolean(pendingById[claimId]);
}); }
);
export const makeSelectPendingByUri = uri => export const makeSelectPendingByUri = (uri: string) =>
createSelector(selectPendingById, pendingById => { createSelector(
selectPendingById,
pendingById => {
const { claimId } = parseURI(uri); const { claimId } = parseURI(uri);
return pendingById[claimId]; return pendingById[claimId];
}); }
);
export const makeSelectClaimForUri = uri => export const makeSelectClaimForUri = (uri: string) =>
createSelector(selectClaimsByUri, selectPendingById, (byUri, pendingById) => { createSelector(
selectClaimsByUri,
selectPendingById,
(byUri, pendingById) => {
// Check if a claim is pending first // Check if a claim is pending first
// It won't be in claimsByUri because resolving it will return nothing // It won't be in claimsByUri because resolving it will return nothing
const { claimId } = parseURI(uri); const { claimId } = parseURI(uri);
@ -67,12 +88,17 @@ export const makeSelectClaimForUri = uri =>
} }
return byUri && byUri[normalizeURI(uri)]; return byUri && byUri[normalizeURI(uri)];
}); }
);
export const selectMyClaimsRaw = createSelector(selectState, state => state.myClaims); export const selectMyClaimsRaw = createSelector(
selectState,
state => state.myClaims
);
export const selectAbandoningIds = createSelector(selectState, state => export const selectAbandoningIds = createSelector(
Object.keys(state.abandoningById || {}) selectState,
state => Object.keys(state.abandoningById || {})
); );
export const selectMyActiveClaims = createSelector( export const selectMyActiveClaims = createSelector(
@ -87,7 +113,7 @@ export const selectMyActiveClaims = createSelector(
) )
); );
export const makeSelectClaimIsMine = rawUri => { export const makeSelectClaimIsMine = (rawUri: string) => {
const uri = normalizeURI(rawUri); const uri = normalizeURI(rawUri);
return createSelector( return createSelector(
selectClaimsByUri, selectClaimsByUri,
@ -102,20 +128,27 @@ export const selectAllFetchingChannelClaims = createSelector(
state => state.fetchingChannelClaims || {} state => state.fetchingChannelClaims || {}
); );
export const makeSelectFetchingChannelClaims = uri => export const makeSelectFetchingChannelClaims = (uri: string) =>
createSelector(selectAllFetchingChannelClaims, fetching => fetching && fetching[uri]); createSelector(
selectAllFetchingChannelClaims,
fetching => fetching && fetching[uri]
);
export const makeSelectClaimsInChannelForPage = (uri, page) => export const makeSelectClaimsInChannelForPage = (uri: string, page?: number) =>
createSelector(selectClaimsById, selectAllClaimsByChannel, (byId, allClaims) => { createSelector(
selectClaimsById,
selectAllClaimsByChannel,
(byId, allClaims) => {
const byChannel = allClaims[uri] || {}; const byChannel = allClaims[uri] || {};
const claimIds = byChannel[page || 1]; const claimIds = byChannel[page || 1];
if (!claimIds) return claimIds; if (!claimIds) return claimIds;
return claimIds.map(claimId => byId[claimId]); return claimIds.map(claimId => byId[claimId]);
}); }
);
export const makeSelectClaimsInChannelForCurrentPageState = uri => export const makeSelectClaimsInChannelForCurrentPageState = (uri: string) =>
createSelector( createSelector(
selectClaimsById, selectClaimsById,
selectAllClaimsByChannel, selectAllClaimsByChannel,
@ -130,21 +163,38 @@ export const makeSelectClaimsInChannelForCurrentPageState = uri =>
} }
); );
export const makeSelectMetadataForUri = uri => export const makeSelectMetadataForUri = (uri: string) =>
createSelector(makeSelectClaimForUri(uri), claim => { createSelector(
const metadata = claim && claim.value && claim.value.stream && claim.value.stream.metadata; makeSelectClaimForUri(uri),
claim => {
const metadata = claim && claim.value;
return metadata || (claim === undefined ? undefined : null); return metadata || (claim === undefined ? undefined : null);
}); }
);
export const makeSelectTitleForUri = uri => export const makeSelectTitleForUri = (uri: string) =>
createSelector(makeSelectMetadataForUri(uri), metadata => metadata && metadata.title); createSelector(
makeSelectMetadataForUri(uri),
metadata => metadata && metadata.title
);
export const makeSelectContentTypeForUri = uri => export const makeSelectContentTypeForUri = (uri: string) =>
createSelector(makeSelectClaimForUri(uri), claim => { createSelector(
const source = claim && claim.value && claim.value.stream && claim.value.stream.source; makeSelectClaimForUri(uri),
return source ? source.contentType : undefined; claim => {
}); const source = claim && claim.value && claim.value.source;
return source ? source.media_type : undefined;
}
);
export const makeSelectThumbnailForUri = (uri: string) =>
createSelector(
makeSelectClaimForUri(uri),
claim => {
const thumbnail = claim && claim.value && claim.value.thumbnail;
return thumbnail ? thumbnail.url : undefined;
}
);
export const selectIsFetchingClaimListMine = createSelector( export const selectIsFetchingClaimListMine = createSelector(
selectState, selectState,
@ -169,8 +219,9 @@ export const selectMyClaims = createSelector(
} }
); );
export const selectMyClaimsWithoutChannels = createSelector(selectMyClaims, myClaims => export const selectMyClaimsWithoutChannels = createSelector(
myClaims.filter(claim => !claim.name.match(/^@/)) selectMyClaims,
myClaims => myClaims.filter(claim => !claim.name.match(/^@/))
); );
export const selectAllMyClaimsByOutpoint = createSelector( export const selectAllMyClaimsByOutpoint = createSelector(
@ -179,13 +230,16 @@ export const selectAllMyClaimsByOutpoint = createSelector(
new Set(claims && claims.length ? claims.map(claim => `${claim.txid}:${claim.nout}`) : null) new Set(claims && claims.length ? claims.map(claim => `${claim.txid}:${claim.nout}`) : null)
); );
export const selectMyClaimsOutpoints = createSelector(selectMyClaims, myClaims => { export const selectMyClaimsOutpoints = createSelector(
selectMyClaims,
myClaims => {
const outpoints = []; const outpoints = [];
myClaims.forEach(claim => outpoints.push(`${claim.txid}:${claim.nout}`)); myClaims.forEach(claim => outpoints.push(`${claim.txid}:${claim.nout}`));
return outpoints; return outpoints;
}); }
);
export const selectFetchingMyChannels = createSelector( export const selectFetchingMyChannels = createSelector(
selectState, selectState,
@ -210,42 +264,53 @@ export const selectMyChannelClaims = createSelector(
} }
); );
export const selectResolvingUris = createSelector(selectState, state => state.resolvingUris || []); export const selectResolvingUris = createSelector(
selectState,
state => state.resolvingUris || []
);
export const makeSelectIsUriResolving = uri => export const makeSelectIsUriResolving = (uri: string) =>
createSelector( createSelector(
selectResolvingUris, selectResolvingUris,
resolvingUris => resolvingUris && resolvingUris.indexOf(uri) !== -1 resolvingUris => resolvingUris && resolvingUris.indexOf(uri) !== -1
); );
export const selectPlayingUri = createSelector(selectState, state => state.playingUri); export const selectPlayingUri = createSelector(
selectState,
state => state.playingUri
);
export const selectChannelClaimCounts = createSelector( export const selectChannelClaimCounts = createSelector(
selectState, selectState,
state => state.channelClaimCounts || {} state => state.channelClaimCounts || {}
); );
export const makeSelectTotalItemsForChannel = uri => export const makeSelectTotalItemsForChannel = (uri: string) =>
createSelector(selectChannelClaimCounts, byUri => byUri && byUri[uri]); createSelector(
selectChannelClaimCounts,
byUri => byUri && byUri[uri]
);
export const makeSelectTotalPagesForChannel = (uri, pageSize = 10) => export const makeSelectTotalPagesForChannel = (uri: string, pageSize: number = 10) =>
createSelector( createSelector(
selectChannelClaimCounts, selectChannelClaimCounts,
byUri => byUri && byUri[uri] && Math.ceil(byUri[uri] / pageSize) byUri => byUri && byUri[uri] && Math.ceil(byUri[uri] / pageSize)
); );
export const makeSelectNsfwCountFromUris = uris => export const makeSelectNsfwCountFromUris = (uris: Array<string>) =>
createSelector(selectClaimsByUri, claims => createSelector(
selectClaimsByUri,
claims =>
uris.reduce((acc, uri) => { uris.reduce((acc, uri) => {
const claim = claims[uri]; const claim = claims[uri];
if (isClaimNsfw(claim)) { if (claim && isClaimNsfw(claim)) {
return acc + 1; return acc + 1;
} }
return acc; return acc;
}, 0) }, 0)
); );
export const makeSelectNsfwCountForChannel = uri => export const makeSelectNsfwCountForChannel = (uri: string) =>
createSelector( createSelector(
selectClaimsById, selectClaimsById,
selectAllClaimsByChannel, selectAllClaimsByChannel,
@ -266,7 +331,7 @@ export const makeSelectNsfwCountForChannel = uri =>
} }
); );
export const makeSelectRecommendedContentForUri = uri => export const makeSelectRecommendedContentForUri = (uri: string) =>
createSelector( createSelector(
makeSelectClaimForUri(uri), makeSelectClaimForUri(uri),
selectSearchUrisByQuery, selectSearchUrisByQuery,
@ -280,7 +345,7 @@ export const makeSelectRecommendedContentForUri = uri =>
? buildURI({ claimId: claim.claim_id, claimName: claim.name }) ? buildURI({ claimId: claim.claim_id, claimName: claim.name })
: uri; : uri;
const { title } = claim.value.stream.metadata; const { title } = claim.value;
const searchQuery = getSearchQueryString(title.replace(/\//, ' ')); const searchQuery = getSearchQueryString(title.replace(/\//, ' '));
@ -295,24 +360,25 @@ export const makeSelectRecommendedContentForUri = uri =>
} }
); );
export const makeSelectFirstRecommendedFileForUri = uri => export const makeSelectFirstRecommendedFileForUri = (uri: string) =>
createSelector( createSelector(
makeSelectRecommendedContentForUri(uri), makeSelectRecommendedContentForUri(uri),
recommendedContent => (recommendedContent ? recommendedContent[0] : null) recommendedContent => (recommendedContent ? recommendedContent[0] : null)
); );
// Returns the associated channel uri for a given claim uri // Returns the associated channel uri for a given claim uri
export const makeSelectChannelForClaimUri = (uri, includePrefix = false) => // accepts a regular claim uri lbry://something
createSelector(makeSelectClaimForUri(uri), claim => { // returns the channel uri that created this claim lbry://@channel
if (!claim) { export const makeSelectChannelForClaimUri = (uri: string, includePrefix: boolean = false) =>
createSelector(
makeSelectClaimForUri(uri),
(claim: ?StreamClaim) => {
if (!claim || !claim.signing_channel) {
return null; return null;
} }
const { channel_name: channelName, value } = claim; const { claim_id: claimId, name } = claim.signing_channel;
const channelClaimId = let channel = `${name}#${claimId}`;
value && value.publisherSignature && value.publisherSignature.certificateId; return includePrefix ? `lbry://${channel}` : channel;
}
return channelName && channelClaimId );
? buildURI({ channelName, claimId: channelClaimId }, includePrefix)
: null;
});

View file

@ -1,5 +1,4 @@
// @flow // @flow
import type { SearchState, SearchOptions, SearchSuggestion } from 'types/Search';
import { SEARCH_TYPES, SEARCH_OPTIONS } from 'constants/search'; import { SEARCH_TYPES, SEARCH_OPTIONS } from 'constants/search';
import { getSearchQueryString } from 'util/query_params'; import { getSearchQueryString } from 'util/query_params';
import { normalizeURI, parseURI } from 'lbryURI'; import { normalizeURI, parseURI } from 'lbryURI';
@ -33,7 +32,10 @@ export const selectIsSearching: (state: State) => boolean = createSelector(
export const selectSearchUrisByQuery: ( export const selectSearchUrisByQuery: (
state: State state: State
) => { [string]: Array<string> } = createSelector(selectState, state => state.urisByQuery); ) => { [string]: Array<string> } = createSelector(
selectState,
state => state.urisByQuery
);
export const makeSelectSearchUris = (query: string): ((state: State) => Array<string>) => export const makeSelectSearchUris = (query: string): ((state: State) => Array<string>) =>
// replace statement below is kind of ugly, and repeated in doSearch action // replace statement below is kind of ugly, and repeated in doSearch action
@ -42,7 +44,10 @@ export const makeSelectSearchUris = (query: string): ((state: State) => Array<st
byQuery => byQuery[query ? query.replace(/^lbry:\/\//i, '').replace(/\//, ' ') : query] byQuery => byQuery[query ? query.replace(/^lbry:\/\//i, '').replace(/\//, ' ') : query]
); );
export const selectSearchBarFocused: boolean = createSelector(selectState, state => state.focused); export const selectSearchBarFocused: boolean = createSelector(
selectState,
state => state.focused
);
export const selectSearchSuggestions: Array<SearchSuggestion> = createSelector( export const selectSearchSuggestions: Array<SearchSuggestion> = createSelector(
selectSearchValue, selectSearchValue,
@ -93,7 +98,9 @@ export const selectSearchSuggestions: Array<SearchSuggestion> = createSelector(
const apiSuggestions = suggestions[query] || []; const apiSuggestions = suggestions[query] || [];
if (apiSuggestions.length) { if (apiSuggestions.length) {
searchSuggestions = searchSuggestions.concat( searchSuggestions = searchSuggestions.concat(
apiSuggestions.filter(suggestion => suggestion !== query).map(suggestion => { apiSuggestions
.filter(suggestion => suggestion !== query)
.map(suggestion => {
// determine if it's a channel // determine if it's a channel
try { try {
const uri = normalizeURI(suggestion); const uri = normalizeURI(suggestion);
@ -127,7 +134,10 @@ export const makeSelectQueryWithOptions = (
customFrom: ?number, customFrom: ?number,
isBackgroundSearch: boolean = false // If it's a background search, don't use the users settings isBackgroundSearch: boolean = false // If it's a background search, don't use the users settings
) => ) =>
createSelector(selectSearchValue, selectSearchOptions, (query, options) => { createSelector(
selectSearchValue,
selectSearchOptions,
(query, options) => {
const size = customSize || options[SEARCH_OPTIONS.RESULT_COUNT]; const size = customSize || options[SEARCH_OPTIONS.RESULT_COUNT];
const queryString = getSearchQueryString( const queryString = getSearchQueryString(
@ -137,4 +147,5 @@ export const makeSelectQueryWithOptions = (
); );
return queryString; return queryString;
}); }
);

View file

@ -1,2 +1,25 @@
export const isClaimNsfw = claim => // @flow
claim && claim.value && claim.value.stream && claim.value.stream.metadata.nsfw;
const naughtyTags = ['porn', 'nsfw', 'mature', 'xxx'].reduce(
(acc, tag) => ({ ...acc, [tag]: true }),
{}
);
export const isClaimNsfw = (claim: StreamClaim): boolean => {
if (!claim) {
throw new Error('No claim passed to isClaimNsfw()');
}
if (!claim.value) {
return false;
}
const tags = claim.value.tags || [];
for (let i = 0; i < tags.length; i += 1) {
if (naughtyTags[tags[i]]) {
return true;
}
}
return false;
};

View file

@ -1,4 +1,5 @@
export default function handleFetchResponse(response) { // @flow
export default function handleFetchResponse(response: Response): Promise<any> {
return response.status === 200 return response.status === 200
? Promise.resolve(response.json()) ? Promise.resolve(response.json())
: Promise.reject(new Error(response.statusText)); : Promise.reject(new Error(response.statusText));

View file

@ -1,27 +0,0 @@
/* eslint-disable import/no-commonjs */
const path = require('path');
const FlowWebpackPlugin = require('flow-webpack-plugin');
module.exports = {
mode: 'none',
entry: './src/index.js',
output: {
filename: 'bundle.js',
path: path.resolve(__dirname, 'dist'),
libraryTarget: 'umd',
globalObject: `(typeof self !== 'undefined' ? self : this)`,
},
module: {
rules: [
{
test: /\.js$/,
exclude: /node_modules/,
loader: 'babel-loader',
},
],
},
resolve: {
modules: [path.resolve(__dirname, 'src'), 'node_modules'],
},
plugins: [new FlowWebpackPlugin()],
};

3413
yarn.lock

File diff suppressed because it is too large Load diff