@griddo/ax 12.2.3-rc.0 → 12.2.3-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/config/webpack.config.js
CHANGED
|
@@ -166,6 +166,11 @@ module.exports = function (webpackEnv) {
|
|
|
166
166
|
|
|
167
167
|
return {
|
|
168
168
|
mode: isEnvProduction ? "production" : isEnvDevelopment && "development",
|
|
169
|
+
// Pin the target instead of letting webpack 5 derive it from the client
|
|
170
|
+
// project's browserslist: queries like "maintained node versions" (common
|
|
171
|
+
// in Gatsby-rendered projects) drop the `document` capability and switch
|
|
172
|
+
// chunks to ESM format, which breaks the editor's classic script tags.
|
|
173
|
+
target: ["web", "es2017"],
|
|
169
174
|
// Stop compilation early in production
|
|
170
175
|
bail: isEnvProduction,
|
|
171
176
|
devtool: isEnvProduction
|
|
@@ -331,7 +336,15 @@ module.exports = function (webpackEnv) {
|
|
|
331
336
|
},
|
|
332
337
|
},
|
|
333
338
|
module: {
|
|
334
|
-
|
|
339
|
+
// Missing exports must stay non-blocking: webpack 4's CJS css-loader
|
|
340
|
+
// never validated CSS-module classes, so client projects accumulated
|
|
341
|
+
// references to classes that don't exist. With webpack 5 named exports
|
|
342
|
+
// those would all become compile errors and block adoption.
|
|
343
|
+
parser: {
|
|
344
|
+
javascript: {
|
|
345
|
+
exportsPresence: "warn",
|
|
346
|
+
},
|
|
347
|
+
},
|
|
335
348
|
rules: [
|
|
336
349
|
{
|
|
337
350
|
// "oneOf" will traverse all following loaders until one will
|
|
@@ -641,6 +654,10 @@ module.exports = function (webpackEnv) {
|
|
|
641
654
|
typescriptPath: resolve.sync("typescript", {
|
|
642
655
|
basedir: paths.appNodeModules,
|
|
643
656
|
}),
|
|
657
|
+
// Must be an absolute path: fork-ts-checker v6 resolves a relative
|
|
658
|
+
// "tsconfig.json" against the webpack compiler context (the client
|
|
659
|
+
// project cwd), which would pick up the client's tsconfig instead.
|
|
660
|
+
configFile: paths.appTsConfig,
|
|
644
661
|
configOverwrite: {
|
|
645
662
|
compilerOptions: {
|
|
646
663
|
sourceMap: isEnvProduction ? shouldUseSourceMap : isEnvDevelopment,
|
|
@@ -662,16 +679,26 @@ module.exports = function (webpackEnv) {
|
|
|
662
679
|
include: [{ file: "../**/src/**/*.{ts,tsx}" }, { file: "**/src/**/*.{ts,tsx}" }],
|
|
663
680
|
exclude: [
|
|
664
681
|
{ file: "**/src/**/__tests__/**" },
|
|
665
|
-
{ file: "**/src/**/?(*.)
|
|
682
|
+
{ file: "**/src/**/?(*.)(spec|test).*" },
|
|
666
683
|
{ file: "**/src/setupProxy.*" },
|
|
667
684
|
{ file: "**/src/setupTests.*" },
|
|
668
685
|
],
|
|
669
686
|
},
|
|
670
687
|
logger: {
|
|
671
688
|
infrastructure: "silent",
|
|
689
|
+
// Progress lines ("Files successfully emitted…", "No issues
|
|
690
|
+
// found."). Actual TS errors still reach webpack's compilation
|
|
691
|
+
// and are printed by react-dev-utils.
|
|
692
|
+
issues: "silent",
|
|
672
693
|
},
|
|
673
694
|
}),
|
|
674
695
|
].filter(Boolean),
|
|
696
|
+
// Silence webpack-dev-middleware's stats dump on every (re)build —
|
|
697
|
+
// webpack 4's dev server did this via `quiet: true`. react-dev-utils
|
|
698
|
+
// still prints the friendly "Compiled successfully" + URLs block.
|
|
699
|
+
infrastructureLogging: {
|
|
700
|
+
level: "none",
|
|
701
|
+
},
|
|
675
702
|
// Turn off performance processing because we utilize
|
|
676
703
|
// our own hints via the FileSizeReporter
|
|
677
704
|
performance: false,
|
|
@@ -54,6 +54,10 @@ module.exports = function (proxy, allowedHost) {
|
|
|
54
54
|
},
|
|
55
55
|
devMiddleware: {
|
|
56
56
|
publicPath: paths.publicUrlOrPath.slice(0, -1),
|
|
57
|
+
// webpack-dev-middleware prints stats.toString() with a raw
|
|
58
|
+
// console.log (not the infrastructure logger), so this is the only
|
|
59
|
+
// switch that silences the per-build stats dump.
|
|
60
|
+
stats: "none",
|
|
57
61
|
},
|
|
58
62
|
https: getHttpsConfig(),
|
|
59
63
|
host,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@griddo/ax",
|
|
3
3
|
"description": "Griddo Author Experience",
|
|
4
|
-
"version": "12.2.3-rc.
|
|
4
|
+
"version": "12.2.3-rc.1",
|
|
5
5
|
"authors": [
|
|
6
6
|
"Álvaro Sánchez' <alvaro.sanches@secuoyas.com>",
|
|
7
7
|
"Diego M. Béjar <diego.bejar@secuoyas.com>",
|
|
@@ -213,5 +213,5 @@
|
|
|
213
213
|
"publishConfig": {
|
|
214
214
|
"access": "public"
|
|
215
215
|
},
|
|
216
|
-
"gitHead": "
|
|
216
|
+
"gitHead": "f328137a3b2bb2527d7d849e0ca9a2adec6f03cb"
|
|
217
217
|
}
|
package/scripts/start.js
CHANGED
|
@@ -72,6 +72,36 @@ checkBrowsers(paths.appPath, isInteractive)
|
|
|
72
72
|
tscCompileOnError,
|
|
73
73
|
webpack,
|
|
74
74
|
});
|
|
75
|
+
// Replace CRA's "You can now view..." block with the Griddo banner.
|
|
76
|
+
// Registered after createCompiler so it runs after CRA's done-hook:
|
|
77
|
+
// clean builds clear that output, builds with warnings keep it visible.
|
|
78
|
+
const { version } = require(paths.appPackageJson);
|
|
79
|
+
const banner = [
|
|
80
|
+
chalk.cyan(" ██████╗ ██████╗ ██╗██████╗ ██████╗ ██████╗ █████╗ ██╗ ██╗"),
|
|
81
|
+
chalk.cyan("██╔════╝ ██╔══██╗██║██╔══██╗██╔══██╗██╔═══██╗ ██╔══██╗╚██╗██╔╝"),
|
|
82
|
+
chalk.cyan("██║ ███╗██████╔╝██║██║ ██║██║ ██║██║ ██║ ███████║ ╚███╔╝"),
|
|
83
|
+
chalk.cyan("██║ ██║██╔══██╗██║██║ ██║██║ ██║██║ ██║ ██╔══██║ ██╔██╗"),
|
|
84
|
+
chalk.cyan("╚██████╔╝██║ ██║██║██████╔╝██████╔╝╚██████╔╝ ██║ ██║██╔╝ ██╗"),
|
|
85
|
+
chalk.cyan(" ╚═════╝ ╚═╝ ╚═╝╚═╝╚═════╝ ╚═════╝ ╚═════╝ ╚═╝ ╚═╝╚═╝ ╚═╝"),
|
|
86
|
+
chalk.dim(`v${version}`),
|
|
87
|
+
"",
|
|
88
|
+
chalk.dim("─".repeat(63)),
|
|
89
|
+
"",
|
|
90
|
+
`${chalk.bold("Local:")} ${urls.localUrlForTerminal}`,
|
|
91
|
+
...(urls.lanUrlForTerminal ? [`${chalk.bold("On Your Network:")} ${urls.lanUrlForTerminal}`] : []),
|
|
92
|
+
]
|
|
93
|
+
.map((line) => ` ${line}`)
|
|
94
|
+
.join("\n");
|
|
95
|
+
compiler.hooks.done.tap("griddoStartBanner", (stats) => {
|
|
96
|
+
const statsData = stats.toJson({ all: false, errors: true, warnings: true });
|
|
97
|
+
if (statsData.errors.length) {
|
|
98
|
+
return;
|
|
99
|
+
}
|
|
100
|
+
if (isInteractive && !statsData.warnings.length) {
|
|
101
|
+
clearConsole();
|
|
102
|
+
}
|
|
103
|
+
console.log(`\n${banner}\n`);
|
|
104
|
+
});
|
|
75
105
|
// Load proxy config
|
|
76
106
|
const proxySetting = require(paths.appPackageJson).proxy;
|
|
77
107
|
const proxyConfig = prepareProxy(proxySetting, paths.appPublic, paths.publicUrlOrPath);
|