@@ -1,20 +1,14 @@
|
||||
const webpack = require('webpack')
|
||||
const middleware = require('webpack-dev-middleware')
|
||||
const config = require('../webpack.config')
|
||||
const FriendlyErrorsWebpackPlugin = require('friendly-errors-webpack-plugin')
|
||||
|
||||
const webpackCompiler = webpack({
|
||||
...config,
|
||||
mode: 'development',
|
||||
plugins: [
|
||||
...config.plugins,
|
||||
new FriendlyErrorsWebpackPlugin({
|
||||
clearConsole: false
|
||||
})
|
||||
...config.plugins
|
||||
]
|
||||
})
|
||||
|
||||
module.exports = middleware(webpackCompiler, {
|
||||
publicPath: config.output.publicPath,
|
||||
logLevel: 'silent'
|
||||
publicPath: config.output.publicPath
|
||||
})
|
||||
|
||||
3568
package-lock.json
generated
3568
package-lock.json
generated
File diff suppressed because it is too large
Load Diff
13
package.json
13
package.json
@@ -24,7 +24,9 @@
|
||||
"@octokit/rest": "^16.38.1",
|
||||
"@primer/css": "^16.2.0",
|
||||
"@primer/octicons": "^13.0.0",
|
||||
"ajv": "^6.11.0",
|
||||
"algoliasearch": "^3.35.1",
|
||||
"assert": "^2.0.0",
|
||||
"babel-loader": "^8.1.0",
|
||||
"babel-preset-env": "^1.7.0",
|
||||
"browser-date-formatter": "^3.0.3",
|
||||
@@ -67,7 +69,7 @@
|
||||
"lunr": "^2.3.9",
|
||||
"lunr-languages": "^1.4.0",
|
||||
"mdast-util-from-markdown": "^0.8.4",
|
||||
"mini-css-extract-plugin": "^0.9.0",
|
||||
"mini-css-extract-plugin": "^1.4.1",
|
||||
"mkdirp": "^1.0.3",
|
||||
"morgan": "^1.9.1",
|
||||
"node-fetch": "^2.6.1",
|
||||
@@ -103,13 +105,12 @@
|
||||
"unist-util-visit": "^2.0.3",
|
||||
"uuid": "^8.3.0",
|
||||
"walk-sync": "^1.1.4",
|
||||
"webpack": "^4.44.0",
|
||||
"webpack-cli": "^3.3.12"
|
||||
"webpack": "^5.30.0",
|
||||
"webpack-cli": "^4.6.0"
|
||||
},
|
||||
"devDependencies": {
|
||||
"@actions/core": "^1.2.6",
|
||||
"@actions/github": "^4.0.0",
|
||||
"ajv": "^6.11.0",
|
||||
"async": "^3.2.0",
|
||||
"await-sleep": "0.0.1",
|
||||
"aws-sdk": "^2.610.0",
|
||||
@@ -130,7 +131,6 @@
|
||||
"eslint-plugin-node": "^11.1.0",
|
||||
"eslint-plugin-promise": "^4.2.1",
|
||||
"event-to-promise": "^0.8.0",
|
||||
"friendly-errors-webpack-plugin": "^1.7.0",
|
||||
"graphql": "^14.5.8",
|
||||
"heroku-client": "^3.1.0",
|
||||
"http-status-code": "^2.1.0",
|
||||
@@ -155,6 +155,7 @@
|
||||
"object-hash": "^2.0.1",
|
||||
"pa11y-ci": "^2.4.0",
|
||||
"prettier": "^2.1.2",
|
||||
"process": "^0.11.10",
|
||||
"puppeteer": "^5.5.0",
|
||||
"replace": "^1.2.0",
|
||||
"robots-parser": "^2.1.1",
|
||||
@@ -162,7 +163,7 @@
|
||||
"strip-ansi": "^6.0.0",
|
||||
"supertest": "^4.0.2",
|
||||
"url-template": "^2.0.8",
|
||||
"webpack-dev-middleware": "^3.7.2",
|
||||
"webpack-dev-middleware": "^4.1.0",
|
||||
"website-scraper": "^4.2.0",
|
||||
"xlsx-populate": "^1.21.0"
|
||||
},
|
||||
|
||||
@@ -47,7 +47,8 @@ const main = async () => {
|
||||
'imurmurhash',
|
||||
'js-cookie',
|
||||
'mdast-util-from-markdown',
|
||||
'unist-util-visit'
|
||||
'unist-util-visit',
|
||||
'assert'
|
||||
]
|
||||
})
|
||||
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
const path = require('path')
|
||||
const MiniCssExtractPlugin = require('mini-css-extract-plugin')
|
||||
const CopyWebpackPlugin = require('copy-webpack-plugin')
|
||||
const { EnvironmentPlugin } = require('webpack')
|
||||
const { EnvironmentPlugin, ProvidePlugin } = require('webpack')
|
||||
const { reactBabelOptions } = require('./lib/react/babel')
|
||||
|
||||
module.exports = {
|
||||
mode: 'development',
|
||||
devtool: 'source-map', // this prevents webpack from using eval
|
||||
entry: './javascripts/index.js',
|
||||
output: {
|
||||
@@ -12,6 +13,7 @@ module.exports = {
|
||||
path: path.resolve(__dirname, 'dist'),
|
||||
publicPath: '/dist'
|
||||
},
|
||||
stats: 'errors-only',
|
||||
module: {
|
||||
rules: [
|
||||
{
|
||||
@@ -85,6 +87,12 @@ module.exports = {
|
||||
{ from: 'node_modules/@primer/css/fonts', to: 'fonts' }
|
||||
]
|
||||
}),
|
||||
new EnvironmentPlugin(['NODE_ENV'])
|
||||
new EnvironmentPlugin({
|
||||
NODE_ENV: 'development', // use 'development' unless process.env.NODE_ENV is defined
|
||||
DEBUG: false
|
||||
}),
|
||||
new ProvidePlugin({
|
||||
process: 'process/browser'
|
||||
})
|
||||
]
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user