Set threadpool size in server.js
parent
2423d09a4f
commit
bec58a3bec
|
@ -1,13 +1,13 @@
|
||||||
{
|
{
|
||||||
"name": "react-toolbox",
|
"name": "react-toolbox",
|
||||||
"version": "0.10.20",
|
"version": "0.10.28",
|
||||||
"description": "A set of complementary tools to ReactJS.",
|
"description": "A set of complementary tools to ReactJS.",
|
||||||
"author": "React Toolbox Team (http://github.com/react-toolbox)",
|
"author": "React Toolbox Team (http://github.com/react-toolbox)",
|
||||||
"contributors": [
|
"contributors": [
|
||||||
{
|
{
|
||||||
"name": "Javi Jimenez Villar",
|
"name": "Javi Jimenez Villar",
|
||||||
"url": "http://soyjavi.com/",
|
"url": "http://soyjavi.com/",
|
||||||
"email": "hi@soyjavi.com"
|
"email": "javi.jimenez.villar@gmail.com"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Javi Velasco Arjona",
|
"name": "Javi Velasco Arjona",
|
||||||
|
@ -17,7 +17,7 @@
|
||||||
],
|
],
|
||||||
"main": "./lib",
|
"main": "./lib",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"start": "UV_THREADPOOL_SIZE=100 node ./server",
|
"start": "node ./server",
|
||||||
"babel": "babel ./components --out-dir ./lib",
|
"babel": "babel ./components --out-dir ./lib",
|
||||||
"build": "npm run lint && npm run babel && npm run sass",
|
"build": "npm run lint && npm run babel && npm run sass",
|
||||||
"clean": "rimraf ./lib",
|
"clean": "rimraf ./lib",
|
||||||
|
|
|
@ -1,3 +1,5 @@
|
||||||
|
process.env.UV_THREADPOOL_SIZE = Math.ceil(Math.max(4, require('os').cpus().length * 1.5));
|
||||||
|
|
||||||
const webpack = require('webpack');
|
const webpack = require('webpack');
|
||||||
const WebpackDevServer = require('webpack-dev-server');
|
const WebpackDevServer = require('webpack-dev-server');
|
||||||
const config = require('./webpack.config.development');
|
const config = require('./webpack.config.development');
|
||||||
|
|
Loading…
Reference in New Issue