Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

perf: upgrade nino-cli to 1.1.0 #179

Merged
merged 1 commit into from
Aug 20, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
15 changes: 7 additions & 8 deletions scripts/build.js → nino.koei.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
const path = require('path');
const cwd = process.cwd();
const CopyWebpackPlugin = require('copy-webpack-plugin');
// const { BundleAnalyzerPlugin } = require('webpack-bundle-analyzer');
const PostCompile = require('post-compile-webpack-plugin');
Expand All @@ -8,16 +7,16 @@ const IO = require('socket.io-client');
const plugins = [
new CopyWebpackPlugin([
{
from: path.join(cwd, 'src/assets'),
to: path.join(cwd, 'dist/assets'),
from: path.join(__dirname, 'src/assets'),
to: path.join(__dirname, 'dist/assets'),
},
{
from: path.join(cwd, '.circleci/config.yml'),
to: path.join(cwd, 'dist/.circleci/config.yml'),
from: path.join(__dirname, '.circleci/config.yml'),
to: path.join(__dirname, 'dist/.circleci/config.yml'),
},
{
from: path.join(cwd, 'src/pages/css'),
to: path.join(cwd, 'dist/src/pages/css'),
from: path.join(__dirname, 'src/pages/css'),
to: path.join(__dirname, 'dist/src/pages/css'),
},
]),
// new BundleAnalyzerPlugin(),
Expand All @@ -34,7 +33,7 @@ if (process.env.BUILD_ENV !== 'prod') {

module.exports = {
entry: {
ninoninoni: path.join(__dirname, '../dist/src'),
ninoninoni: path.join(__dirname, 'dist/src'),
'react-base': ['react', 'react-dom'],
},
plugins,
Expand Down
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -15,13 +15,13 @@
},
"license": "MIT",
"scripts": {
"build": "npm run pre:css && tsc && cross-env BUILD_ENV=prod nino koei -c scripts/build.js",
"build": "npm run pre:css && tsc && cross-env BUILD_ENV=prod nino koei --not-copy-assets",
"clean": "rimraf node_modules package-lock.json bin dist && npm i",
"codecov": "nino test --codecov",
"compile:server": "tsc -p server",
"d": "npm run compile:server -- --watch",
"deploy": "node scripts/publish",
"dev": "npm run pre:css && nino koei -c scripts/build.js -w -d",
"dev": "npm run pre:css && nino koei -w -d --not-copy-assets",
"generate": "node scripts/generateSider",
"lint": "tslint -c tslint.json 'src/**/*.tsx' 'server/**/*.ts'",
"lint-staged": "lint-staged",
Expand Down Expand Up @@ -50,7 +50,7 @@
"core-js": "^3.2.1",
"koa": "^2.8.1",
"mini-xmind": "^1.3.0",
"nino-cli": "^1.0.3",
"nino-cli": "^1.1.0",
"puppeteer-core": "^1.19.0",
"react-lazyload": "^2.6.2",
"react-markdown": "^4.1.0",
Expand Down