@json-layout/core 0.9.2 → 0.9.3
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/package.json +1 -1
- package/src/compile/serialize.js +2 -2
package/package.json
CHANGED
package/src/compile/serialize.js
CHANGED
|
@@ -30,8 +30,8 @@ export function serialize (compiledLayout) {
|
|
|
30
30
|
// some internal imports to ajv are not translated to esm, we do it here
|
|
31
31
|
// cf https://github.com/ajv-validator/ajv-formats/pull/73
|
|
32
32
|
if (code.includes('require("ajv-formats/dist/formats")')) {
|
|
33
|
-
code = 'import
|
|
34
|
-
code = code.replace(/require\("ajv-formats\/dist\/formats"\)\.fullFormats/g, '
|
|
33
|
+
code = 'import { fullFormats } from "ajv-formats/dist/formats.js";\n' + code
|
|
34
|
+
code = code.replace(/require\("ajv-formats\/dist\/formats"\)\.fullFormats/g, 'fullFormats')
|
|
35
35
|
}
|
|
36
36
|
if (code.includes('require("ajv/dist/runtime/ucs2length")')) {
|
|
37
37
|
code = 'import ucs2length from "ajv/dist/runtime/ucs2length.js";\n' + code
|