chore: final cleanup

This commit is contained in:
Igor Gassmann 2018-04-05 12:54:58 -04:00
parent 2e0752286f
commit 1a2c4645c5
8 changed files with 4080 additions and 6359 deletions

4
.babelrc Normal file
View file

@ -0,0 +1,4 @@
{
"presets": ["env", "stage-2"],
"plugins": ["transform-flow-comments"]
}

View file

@ -1,7 +1,7 @@
{ {
"plugins": ["flowtype"], "plugins": ["flowtype"],
"extends": [ "extends": [
"airbnb", "airbnb-base",
"plugin:import/electron", "plugin:import/electron",
"plugin:flowtype/recommended", "plugin:flowtype/recommended",
"plugin:prettier/recommended" "plugin:prettier/recommended"

9
.flowconfig Normal file
View file

@ -0,0 +1,9 @@
[ignore]
[include]
[libs]
[options]
module.system.node.resolve_dirname=src
module.system.node.resolve_dirname=node_modules

View file

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

File diff suppressed because it is too large Load diff

View file

@ -2,6 +2,10 @@
"name": "lbry-redux", "name": "lbry-redux",
"version": "0.0.1", "version": "0.0.1",
"description": "Common shared components for desktop and mobile.", "description": "Common shared components for desktop and mobile.",
"keywords": [
"lbry"
],
"license": "MIT",
"homepage": "https://lbry.io/", "homepage": "https://lbry.io/",
"bugs": { "bugs": {
"url": "https://github.com/lbryio/lbry-redux/issues" "url": "https://github.com/lbryio/lbry-redux/issues"
@ -14,79 +18,41 @@
"name": "LBRY Inc.", "name": "LBRY Inc.",
"email": "hello@lbry.io" "email": "hello@lbry.io"
}, },
"main": "build/index.js", "main": "dist/bundle.js",
"scripts": { "scripts": {
"build": "webpack", "build": "webpack",
"precommit": "lint-staged", "precommit": "lint-staged",
"lint": "eslint 'src/**/*.{js,jsx}' --fix", "lint": "eslint 'src/**/*.js' --fix",
"format": "prettier 'src/**/*.{js,jsx,scss,json}' --write" "format": "prettier 'src/**/*.{js,json}' --write"
}, },
"keywords": [
"lbry"
],
"dependencies": { "dependencies": {
"amplitude-js": "^4.0.0", "proxy-polyfill": "^0.2.0",
"bluebird": "^3.5.1", "reselect": "^3.0.0"
"classnames": "^2.2.5",
"electron-dl": "^1.6.0",
"from2": "^2.3.0",
"install": "^0.10.2",
"jayson": "^2.0.2",
"jshashes": "^1.0.7",
"proxy-polyfill": "0.1.6",
"rc-progress": "^2.0.6",
"react": "^16.2.0",
"react-redux": "^5.0.3",
"redux": "^3.6.0",
"redux-action-buffer": "^1.1.0",
"redux-logger": "^3.0.1",
"redux-persist": "^4.8.0",
"redux-persist-transform-compress": "^4.2.0",
"redux-persist-transform-filter": "0.0.10",
"reselect": "^3.0.0",
"semver": "^5.3.0",
"tree-kill": "^1.1.0",
"y18n": "^4.0.0"
}, },
"devDependencies": { "devDependencies": {
"babel-core": "^6.26.0",
"babel-eslint": "^8.0.3", "babel-eslint": "^8.0.3",
"babel-loader": "^7.1.4",
"babel-plugin-module-resolver": "^3.0.0", "babel-plugin-module-resolver": "^3.0.0",
"babel-plugin-react-require": "^3.0.0",
"babel-polyfill": "^6.20.0",
"babel-preset-env": "^1.6.1", "babel-preset-env": "^1.6.1",
"babel-preset-react": "^6.24.1",
"babel-preset-stage-2": "^6.18.0", "babel-preset-stage-2": "^6.18.0",
"devtron": "^1.4.0",
"electron": "^1.7.9",
"electron-builder": "^19.49.0",
"electron-devtools-installer": "^2.2.1",
"electron-webpack": "^1.11.0",
"eslint": "^4.19.1", "eslint": "^4.19.1",
"eslint-config-airbnb": "^16.1.0", "eslint-config-airbnb-base": "^12.1.0",
"eslint-config-prettier": "^2.9.0", "eslint-config-prettier": "^2.9.0",
"eslint-import-resolver-webpack": "^0.8.3", "eslint-import-resolver-webpack": "^0.9.0",
"eslint-plugin-flowtype": "^2.40.1", "eslint-plugin-flowtype": "^2.40.1",
"eslint-plugin-import": "^2.8.0", "eslint-plugin-import": "^2.10.0",
"eslint-plugin-jsx-a11y": "^6.0.3",
"eslint-plugin-prettier": "^2.4.0", "eslint-plugin-prettier": "^2.4.0",
"eslint-plugin-react": "^7.5.1", "flow-babel-webpack-plugin": "^1.1.1",
"flow-babel-webpack-plugin": "^1.1.0", "flow-bin": "^0.69.0",
"flow-bin": "^0.61.0", "flow-typed": "^2.4.0",
"flow-typed": "^2.2.3",
"husky": "^0.14.3", "husky": "^0.14.3",
"i18n-extract": "^0.5.1", "lint-staged": "^7.0.4",
"json-loader": "^0.5.4",
"lint-staged": "^6.0.0",
"node-loader": "^0.6.0",
"node-sass": "^4.7.2",
"prettier": "^1.4.2", "prettier": "^1.4.2",
"sass-loader": "^6.0.6", "webpack": "^4.5.0",
"webpack": "^3.10.0", "webpack-cli": "^2.0.14"
"webpack-build-notifier": "^0.1.18"
}, },
"license": "MIT", "engines": {
"lbrySettings": { "yarn": "^1.3"
"lbrynetDaemonVersion": "0.18.0",
"lbrynetDaemonUrlTemplate": "https://github.com/lbryio/lbry/releases/download/vDAEMONVER/lbrynet-daemon-vDAEMONVER-OSNAME.zip"
} }
} }

View file

@ -1,31 +1,25 @@
/* eslint-disable import/no-commonjs */
const path = require('path'); const path = require('path');
const FlowBabelWebpackPlugin = require('flow-babel-webpack-plugin');
module.exports = { module.exports = {
mode: 'none',
entry: './src/index.js', entry: './src/index.js',
output: { output: {
path: path.resolve(__dirname, 'build'), filename: 'bundle.js',
filename: 'index.js', path: path.resolve(__dirname, 'dist'),
libraryTarget: 'umd'
}, },
module: { module: {
rules: [ rules: [
{ {
test: /\.js$/, test: /\.js$/,
include: path.resolve(__dirname, 'src'), exclude: /node_modules/,
exclude: /(node_modules|bower_components|build)/,
use: {
loader: 'babel-loader', loader: 'babel-loader',
options: { },
presets: ['env', 'react', 'stage-2'] ],
}
}
}
]
}, },
resolve: { resolve: {
modules: [path.resolve(__dirname, 'src/'), 'node_modules', __dirname], modules: [path.resolve(__dirname, 'src'), 'node_modules'],
extensions: ['.js', '.jsx', '.scss'],
}, },
externals: { plugins: [new FlowBabelWebpackPlugin()],
'react': 'commonjs react'
}
}; };

4726
yarn.lock

File diff suppressed because it is too large Load diff