feat(SW-706): add Lokalise tooling and codemod

This commit is contained in:
Michael Zetterberg
2025-03-12 07:02:49 +01:00
parent 1c5b116ed8
commit e22fc1f3c8
26 changed files with 1478 additions and 130 deletions

View File

@@ -18,7 +18,12 @@
"test": "jest",
"test:watch": "jest --watch",
"ci:build": "yarn lint && yarn test && yarn build",
"clean": "rm -rf .next"
"clean": "rm -rf .next",
"i18n:extract": "formatjs extract \"{actions,app,components,constants,hooks,i18n,lib,middlewares,server,stores,utils}/**/*.{ts,tsx}\" --format i18n/tooling/formatter.mjs --out-file i18n/tooling/extracted.json",
"i18n:upload": "jiti i18n/tooling/upload.ts",
"i18n:download": "jiti i18n/tooling/download.ts",
"i18n:compile": "formatjs compile-folder --ast --format i18n/tooling/formatter.mjs i18n/tooling/translations i18n/dictionaries2",
"i18n:sync": "yarn i18n:extract && yarn i18n:upload && yarn i18n:download && yarn i18n:compile"
},
"dependencies": {
"@azure/monitor-opentelemetry-exporter": "^1.0.0-beta.27",
@@ -104,11 +109,15 @@
"zustand": "^4.5.2"
},
"devDependencies": {
"@formatjs/cli": "^6.6.1",
"@formatjs/swc-plugin-experimental": "0.4.0",
"@lokalise/node-api": "^14.0.0",
"@scandic-hotels/typescript-config": "workspace:*",
"@svgr/webpack": "^8.1.0",
"@testing-library/jest-dom": "^6.4.6",
"@testing-library/react": "^16.0.0",
"@testing-library/user-event": "^14.5.2",
"@types/adm-zip": "^0.5.7",
"@types/jest": "^29.5.12",
"@types/json-stable-stringify-without-jsonify": "^1.0.2",
"@types/node": "^20",
@@ -116,10 +125,12 @@
"@types/react-dom": "^18",
"@typescript-eslint/eslint-plugin": "^8.17.0",
"@typescript-eslint/parser": "^8.17.0",
"adm-zip": "^0.5.16",
"cypress": "^13.6.6",
"dotenv": "^16.4.5",
"eslint": "^8",
"eslint-config-next": "^14.0.4",
"eslint-plugin-formatjs": "^5.2.14",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-simple-import-sort": "^12.1.0",
"jest": "^29.7.0",
@@ -133,6 +144,7 @@
"react-material-symbols": "^4.4.0",
"schema-dts": "^1.1.2",
"start-server-and-test": "^2.0.3",
"ts-morph": "^25.0.1",
"ts-node": "^10.9.2",
"typescript": "5.4.5",
"typescript-plugin-css-modules": "^5.1.0"