Adding Analyzer, Adding more Purge CSS Options

This commit is contained in:
Belen Curcio 2020-11-06 20:09:33 -03:00
parent 817fee61cf
commit c2a115ca57
5 changed files with 1106 additions and 36 deletions

23
.editorconfig Normal file
View File

@ -0,0 +1,23 @@
root = true
[*]
indent_style = space
indent_size = 2
tab_width = 4
end_of_line = lf
charset = utf-8
trim_trailing_whitespace = true
insert_final_newline = true
[*.md]
trim_trailing_whitespace = false
[*.js]
quote_type = single
[{*.c,*.cc,*.h,*.hh,*.cpp,*.hpp,*.m,*.mm,*.mpp,*.js,*.java,*.go,*.rs,*.php,*.ng,*.jsx,*.ts,*.d,*.cs,*.swift}]
curly_bracket_next_line = false
spaces_around_operators = true
spaces_around_brackets = outside
# close enough to 1TB
indent_brace_style = K&R

View File

@ -1,4 +1,8 @@
module.exports = { const bundleAnalyzer = require('@next/bundle-analyzer')({
enabled: !!process.env.BUNDLE_ANALYZE
})
module.exports = module.exports = bundleAnalyzer({
images: { images: {
domains: ['cdn11.bigcommerce.com'], domains: ['cdn11.bigcommerce.com'],
}, },
@ -50,4 +54,4 @@ module.exports = {
}, },
] ]
}, },
} });

View File

@ -4,7 +4,9 @@
"scripts": { "scripts": {
"dev": "next dev", "dev": "next dev",
"build": "next build", "build": "next build",
"start": "next start" "start": "next start",
"analyze": "BUNDLE_ANALYZE=both yarn build",
"find:unused": "next-unused"
}, },
"prettier": { "prettier": {
"semi": false, "semi": false,
@ -37,6 +39,7 @@
"tailwindcss": "^1.9" "tailwindcss": "^1.9"
}, },
"devDependencies": { "devDependencies": {
"@next/bundle-analyzer": "^10.0.1",
"@types/bunyan": "^1.8.6", "@types/bunyan": "^1.8.6",
"@types/bunyan-prettystream": "^0.1.31", "@types/bunyan-prettystream": "^0.1.31",
"@types/classnames": "^2.2.10", "@types/classnames": "^2.2.10",
@ -46,6 +49,7 @@
"@types/react": "^16.9.49", "@types/react": "^16.9.49",
"bunyan": "^1.8.14", "bunyan": "^1.8.14",
"bunyan-prettystream": "^0.1.3", "bunyan-prettystream": "^0.1.3",
"next-unused": "^0.0.3",
"postcss-flexbugs-fixes": "^4.2.1", "postcss-flexbugs-fixes": "^4.2.1",
"postcss-preset-env": "^6.7.0", "postcss-preset-env": "^6.7.0",
"prettier": "^2.1.2", "prettier": "^2.1.2",

View File

@ -1,4 +1,7 @@
module.exports = { module.exports = {
future: {
purgeLayersByDefault: true,
},
purge: { purge: {
content: [ content: [
'./pages/**/*.{js,ts,jsx,tsx}', './pages/**/*.{js,ts,jsx,tsx}',

1102
yarn.lock

File diff suppressed because it is too large Load Diff