diff --git a/.babelrc.json b/.babelrc.json index a8fa44243..fc70f4d82 100644 --- a/.babelrc.json +++ b/.babelrc.json @@ -11,7 +11,7 @@ ["@babel/preset-typescript"] ], "plugins": [ - "@babel/plugin-syntax-import-attributes" + "@babel/plugin-syntax-import-assertions" ], "only": ["src/", "spec/"], "ignore": [ diff --git a/package.json b/package.json index 2256f7418..82d3cb16b 100644 --- a/package.json +++ b/package.json @@ -88,7 +88,7 @@ "@adminjs/design-system": "^4.0.3", "@babel/core": "^7.23.9", "@babel/parser": "^7.23.9", - "@babel/plugin-syntax-import-attributes": "^7.23.3", + "@babel/plugin-syntax-import-assertions": "^7.23.3", "@babel/plugin-transform-runtime": "^7.23.9", "@babel/preset-env": "^7.23.9", "@babel/preset-react": "^7.23.3", @@ -174,7 +174,7 @@ "semantic-release-slack-bot": "^4.0.0", "sinon": "^15.0.2", "sinon-chai": "^3.7.0", - "ts-node": "^10.9.2", + "ts-node": "10.8.1", "typescript": "^5.3.3" }, "resolutions": { diff --git a/src/babel.test.config.json b/src/babel.test.config.json index 60742e66f..336c952af 100644 --- a/src/babel.test.config.json +++ b/src/babel.test.config.json @@ -13,7 +13,7 @@ ], "@babel/preset-typescript" ], - "plugins": ["@babel/plugin-syntax-import-attributes"], + "plugins": ["@babel/plugin-syntax-import-assertions"], "only": ["src/", "spec/"], "ignore": [ "src/frontend/assets/scripts/app-bundle.development.js", diff --git a/src/backend/bundler/components.bundler.ts b/src/backend/bundler/components.bundler.ts index ea1bb81c7..1ff1b62b6 100644 --- a/src/backend/bundler/components.bundler.ts +++ b/src/backend/bundler/components.bundler.ts @@ -46,7 +46,7 @@ const input: InputOptions = { presetReact, presetTs, ], - plugins: ['@babel/plugin-syntax-import-attributes'], + plugins: ['@babel/plugin-syntax-import-assertions'], }), ...(NODE_ENV === 'production' ? [minify()] : []), ], diff --git a/src/locale/index.ts b/src/locale/index.ts index 43bf38cf1..733c3eaad 100644 --- a/src/locale/index.ts +++ b/src/locale/index.ts @@ -1,14 +1,14 @@ import type { LocaleTranslations } from './config.js' -import deLocale from './de/translation.json' with { type: 'json' } -import enLocale from './en/translation.json' with { type: 'json' } -import esLocale from './es/translation.json' with { type: 'json' } -import itLocale from './it/translation.json' with { type: 'json' } -import jaLocale from './ja/translation.json' with { type: 'json' } -import plLocale from './pl/translation.json' with { type: 'json' } -import ptBrLocale from './pt-BR/translation.json' with { type: 'json' } -import uaLocale from './ua/translation.json' with { type: 'json' } -import zhCNLocale from './zh-CN/translation.json' with { type: 'json' } +import deLocale from './de/translation.json' assert { type: 'json' } +import enLocale from './en/translation.json' assert { type: 'json' } +import esLocale from './es/translation.json' assert { type: 'json' } +import itLocale from './it/translation.json' assert { type: 'json' } +import jaLocale from './ja/translation.json' assert { type: 'json' } +import plLocale from './pl/translation.json' assert { type: 'json' } +import ptBrLocale from './pt-BR/translation.json' assert { type: 'json' } +import uaLocale from './ua/translation.json' assert { type: 'json' } +import zhCNLocale from './zh-CN/translation.json' assert { type: 'json' } export * from './config.js' export * from './default-config.js' diff --git a/tsconfig.json b/tsconfig.json index 138877498..e47a0be60 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -1,4 +1,7 @@ { + "ts-node": { + "files": true + }, "compilerOptions": { "outDir": "./built", "target": "esnext", diff --git a/yarn.lock b/yarn.lock index 27c03f9bd..8d14df988 100644 --- a/yarn.lock +++ b/yarn.lock @@ -9842,10 +9842,10 @@ trough@^1.0.0: resolved "https://registry.yarnpkg.com/trough/-/trough-1.0.5.tgz#b8b639cefad7d0bb2abd37d433ff8293efa5f406" integrity sha512-rvuRbTarPXmMb79SmzEp8aqXNKcK+y0XaB298IXueQ8I2PsrATcPBCSPyK/dDNa2iWOhKlfNnOjdAOTBU/nkFA== -ts-node@^10.8.1: - version "10.9.1" - resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.9.1.tgz#e73de9102958af9e1f0b168a6ff320e25adcff4b" - integrity sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw== +ts-node@10.8.1: + version "10.8.1" + resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.8.1.tgz#ea2bd3459011b52699d7e88daa55a45a1af4f066" + integrity sha512-Wwsnao4DQoJsN034wePSg5nZiw4YKXf56mPIAeD6wVmiv+RytNSWqc2f3fKvcUoV+Yn2+yocD71VOfQHbmVX4g== dependencies: "@cspotcode/source-map-support" "^0.8.0" "@tsconfig/node10" "^1.0.7" @@ -9861,10 +9861,10 @@ ts-node@^10.8.1: v8-compile-cache-lib "^3.0.1" yn "3.1.1" -ts-node@^10.9.2: - version "10.9.2" - resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.9.2.tgz#70f021c9e185bccdca820e26dc413805c101c71f" - integrity sha512-f0FFpIdcHgn8zcPSbf1dRevwt047YMnaiJM3u2w2RewrB+fob/zePZcrOyQoLMMO7aBIddLcQIEK5dYjkLnGrQ== +ts-node@^10.8.1: + version "10.9.1" + resolved "https://registry.yarnpkg.com/ts-node/-/ts-node-10.9.1.tgz#e73de9102958af9e1f0b168a6ff320e25adcff4b" + integrity sha512-NtVysVPkxxrwFGUUxGYhfux8k78pQB3JqYBXlLRZgdGUqTO5wU/UyHop5p70iEbGhB7q5KmiZiU0Y3KlJrScEw== dependencies: "@cspotcode/source-map-support" "^0.8.0" "@tsconfig/node10" "^1.0.7"