@intlayer/dictionaries-entry 8.2.4 → 8.3.0-canary.0

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.
@@ -1 +1 @@
1
- {"version":3,"file":"index.cjs","names":["config","configESMxCJSRequire"],"sources":["../../src/index.ts"],"sourcesContent":["/**\n * @intlayer/dictionaries-entry is a package that only returns the dictionary entry file.\n * Using an external package allow to alias it in the bundle configuration (such as webpack).\n * The alias allow hot reload the app (such as nextjs) on any dictionary change.\n */\n\nimport { existsSync } from 'node:fs';\nimport { join } from 'node:path';\nimport config from '@intlayer/config/built';\nimport { clearModuleCache, configESMxCJSRequire } from '@intlayer/config/utils';\nimport type { DictionaryRegistry, IntlayerConfig } from '@intlayer/types';\n\ntype GetDictionaries = (configuration?: IntlayerConfig) => DictionaryRegistry;\n\nexport const getDictionaries: GetDictionaries = (\n configuration: IntlayerConfig = config\n) => {\n const { system, build } = configuration;\n\n // Always use cjs for dictionaries entry as it uses require\n const dictionariesPath = join(system.mainDir, `dictionaries.cjs`);\n\n let dictionaries = {};\n if (existsSync(dictionariesPath)) {\n // Clear cache for dictionaries.cjs and all its dependencies (JSON files)\n clearModuleCache(dictionariesPath);\n\n dictionaries = (build.require ?? configESMxCJSRequire)(dictionariesPath);\n }\n\n return (dictionaries ?? {}) as DictionaryRegistry;\n};\n"],"mappings":"kQAcA,MAAa,GACX,EAAgCA,EAAAA,UAC7B,CACH,GAAM,CAAE,SAAQ,SAAU,EAGpB,GAAA,EAAA,EAAA,MAAwB,EAAO,QAAS,mBAAmB,CAE7D,EAAe,EAAE,CAQrB,OAPA,EAAA,EAAA,YAAe,EAAiB,IAE9B,EAAA,EAAA,kBAAiB,EAAiB,CAElC,GAAgB,EAAM,SAAWC,EAAAA,sBAAsB,EAAiB,EAGlE,GAAgB,EAAE"}
1
+ {"version":3,"file":"index.cjs","names":["config","configESMxCJSRequire"],"sources":["../../src/index.ts"],"sourcesContent":["/**\n * @intlayer/dictionaries-entry is a package that only returns the dictionary entry file.\n * Using an external package allow to alias it in the bundle configuration (such as webpack).\n * The alias allow hot reload the app (such as nextjs) on any dictionary change.\n */\n\nimport { existsSync } from 'node:fs';\nimport { join } from 'node:path';\nimport config from '@intlayer/config/built';\nimport { clearModuleCache, configESMxCJSRequire } from '@intlayer/config/utils';\nimport type { DictionaryRegistry } from '@intlayer/types/module_augmentation';\nimport type { IntlayerConfig } from '@intlayer/types/config';\n\ntype GetDictionaries = (configuration?: IntlayerConfig) => DictionaryRegistry;\n\nexport const getDictionaries: GetDictionaries = (\n configuration: IntlayerConfig = config\n) => {\n const { system, build } = configuration;\n\n // Always use cjs for dictionaries entry as it uses require\n const dictionariesPath = join(system.mainDir, `dictionaries.cjs`);\n\n let dictionaries = {};\n if (existsSync(dictionariesPath)) {\n // Clear cache for dictionaries.cjs and all its dependencies (JSON files)\n clearModuleCache(dictionariesPath);\n\n dictionaries = (build.require ?? configESMxCJSRequire)(dictionariesPath);\n }\n\n return (dictionaries ?? {}) as DictionaryRegistry;\n};\n"],"mappings":"kQAeA,MAAa,GACX,EAAgCA,EAAAA,UAC7B,CACH,GAAM,CAAE,SAAQ,SAAU,EAGpB,GAAA,EAAA,EAAA,MAAwB,EAAO,QAAS,mBAAmB,CAE7D,EAAe,EAAE,CAQrB,OAPA,EAAA,EAAA,YAAe,EAAiB,IAE9B,EAAA,EAAA,kBAAiB,EAAiB,CAElC,GAAgB,EAAM,SAAWC,EAAAA,sBAAsB,EAAiB,EAGlE,GAAgB,EAAE"}
@@ -1 +1 @@
1
- {"version":3,"file":"index.mjs","names":[],"sources":["../../src/index.ts"],"sourcesContent":["/**\n * @intlayer/dictionaries-entry is a package that only returns the dictionary entry file.\n * Using an external package allow to alias it in the bundle configuration (such as webpack).\n * The alias allow hot reload the app (such as nextjs) on any dictionary change.\n */\n\nimport { existsSync } from 'node:fs';\nimport { join } from 'node:path';\nimport config from '@intlayer/config/built';\nimport { clearModuleCache, configESMxCJSRequire } from '@intlayer/config/utils';\nimport type { DictionaryRegistry, IntlayerConfig } from '@intlayer/types';\n\ntype GetDictionaries = (configuration?: IntlayerConfig) => DictionaryRegistry;\n\nexport const getDictionaries: GetDictionaries = (\n configuration: IntlayerConfig = config\n) => {\n const { system, build } = configuration;\n\n // Always use cjs for dictionaries entry as it uses require\n const dictionariesPath = join(system.mainDir, `dictionaries.cjs`);\n\n let dictionaries = {};\n if (existsSync(dictionariesPath)) {\n // Clear cache for dictionaries.cjs and all its dependencies (JSON files)\n clearModuleCache(dictionariesPath);\n\n dictionaries = (build.require ?? configESMxCJSRequire)(dictionariesPath);\n }\n\n return (dictionaries ?? {}) as DictionaryRegistry;\n};\n"],"mappings":"gMAcA,MAAa,GACX,EAAgC,IAC7B,CACH,GAAM,CAAE,SAAQ,SAAU,EAGpB,EAAmB,EAAK,EAAO,QAAS,mBAAmB,CAE7D,EAAe,EAAE,CAQrB,OAPI,EAAW,EAAiB,GAE9B,EAAiB,EAAiB,CAElC,GAAgB,EAAM,SAAW,GAAsB,EAAiB,EAGlE,GAAgB,EAAE"}
1
+ {"version":3,"file":"index.mjs","names":[],"sources":["../../src/index.ts"],"sourcesContent":["/**\n * @intlayer/dictionaries-entry is a package that only returns the dictionary entry file.\n * Using an external package allow to alias it in the bundle configuration (such as webpack).\n * The alias allow hot reload the app (such as nextjs) on any dictionary change.\n */\n\nimport { existsSync } from 'node:fs';\nimport { join } from 'node:path';\nimport config from '@intlayer/config/built';\nimport { clearModuleCache, configESMxCJSRequire } from '@intlayer/config/utils';\nimport type { DictionaryRegistry } from '@intlayer/types/module_augmentation';\nimport type { IntlayerConfig } from '@intlayer/types/config';\n\ntype GetDictionaries = (configuration?: IntlayerConfig) => DictionaryRegistry;\n\nexport const getDictionaries: GetDictionaries = (\n configuration: IntlayerConfig = config\n) => {\n const { system, build } = configuration;\n\n // Always use cjs for dictionaries entry as it uses require\n const dictionariesPath = join(system.mainDir, `dictionaries.cjs`);\n\n let dictionaries = {};\n if (existsSync(dictionariesPath)) {\n // Clear cache for dictionaries.cjs and all its dependencies (JSON files)\n clearModuleCache(dictionariesPath);\n\n dictionaries = (build.require ?? configESMxCJSRequire)(dictionariesPath);\n }\n\n return (dictionaries ?? {}) as DictionaryRegistry;\n};\n"],"mappings":"gMAeA,MAAa,GACX,EAAgC,IAC7B,CACH,GAAM,CAAE,SAAQ,SAAU,EAGpB,EAAmB,EAAK,EAAO,QAAS,mBAAmB,CAE7D,EAAe,EAAE,CAQrB,OAPI,EAAW,EAAiB,GAE9B,EAAiB,EAAiB,CAElC,GAAgB,EAAM,SAAW,GAAsB,EAAiB,EAGlE,GAAgB,EAAE"}
@@ -1,4 +1,5 @@
1
- import { DictionaryRegistry, IntlayerConfig } from "@intlayer/types";
1
+ import { DictionaryRegistry } from "@intlayer/types/module_augmentation";
2
+ import { IntlayerConfig } from "@intlayer/types/config";
2
3
 
3
4
  //#region src/index.d.ts
4
5
  type GetDictionaries = (configuration?: IntlayerConfig) => DictionaryRegistry;
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","names":[],"sources":["../../src/index.ts"],"mappings":";;;KAYK,eAAA,IAAmB,aAAA,GAAgB,cAAA,KAAmB,kBAAA;AAAA,cAE9C,eAAA,EAAiB,eAAA"}
1
+ {"version":3,"file":"index.d.ts","names":[],"sources":["../../src/index.ts"],"mappings":";;;;KAaK,eAAA,IAAmB,aAAA,GAAgB,cAAA,KAAmB,kBAAA;AAAA,cAE9C,eAAA,EAAiB,eAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@intlayer/dictionaries-entry",
3
- "version": "8.2.4",
3
+ "version": "8.3.0-canary.0",
4
4
  "private": false,
5
5
  "description": "Provides the entry path for Intlayer dictionaries, solving filesystem retrieval issues for bundlers like Webpack and Rollup.",
6
6
  "keywords": [
@@ -58,34 +58,34 @@
58
58
  "./package.json"
59
59
  ],
60
60
  "scripts": {
61
- "build": "tsdown --config tsdown.config.ts",
62
- "build:ci": "tsdown --config tsdown.config.ts",
63
- "clean": "rimraf ./dist .turbo",
64
- "dev": "tsdown --config tsdown.config.ts --watch",
65
- "format": "biome format . --check",
66
- "format:fix": "biome format --write .",
67
- "lint": "biome lint .",
68
- "lint:fix": "biome lint --write .",
61
+ "build": "bun --bun tsdown --config tsdown.config.ts",
62
+ "build:ci": "bun --bun tsdown --config tsdown.config.ts",
63
+ "clean": "bun --bun rimraf ./dist .turbo",
64
+ "dev": "bun --bun tsdown --config tsdown.config.ts --watch",
65
+ "format": "bun --bun biome format . --check",
66
+ "format:fix": "bun --bun biome format --write .",
67
+ "lint": "bun --bun biome lint .",
68
+ "lint:fix": "bun --bun biome lint --write .",
69
69
  "process-files": "ts-node src/transpiler/processFilesCLI.ts --dir $npm_config_dir --extension $npm_config_extension --no-node-snapshot",
70
70
  "prepublish": "cp -f ../../../README.md ./README.md",
71
71
  "publish": "bun publish || true",
72
72
  "publish:canary": "bun publish --access public --tag canary || true",
73
73
  "publish:latest": "bun publish --access public --tag latest || true",
74
- "test": "vitest run",
75
- "test:watch": "vitest",
74
+ "test": "bun --bun vitest run",
75
+ "test:watch": "bun --bun vitest",
76
76
  "typecheck": "tsc --noEmit --project tsconfig.types.json"
77
77
  },
78
78
  "dependencies": {
79
- "@intlayer/config": "8.2.3"
79
+ "@intlayer/config": "8.3.0-canary.0"
80
80
  },
81
81
  "devDependencies": {
82
- "@intlayer/types": "8.2.3",
82
+ "@intlayer/types": "8.3.0-canary.0",
83
83
  "@types/node": "25.3.5",
84
84
  "@utils/ts-config": "1.0.4",
85
85
  "@utils/ts-config-types": "1.0.4",
86
86
  "@utils/tsdown-config": "1.0.4",
87
87
  "rimraf": "6.1.3",
88
- "tsdown": "0.21.0",
88
+ "tsdown": "0.21.1",
89
89
  "typescript": "5.9.3",
90
90
  "vitest": "4.0.18"
91
91
  },