@inlang/paraglide-js 1.11.0 → 1.11.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/dist/cli/index.js +4 -42
- package/package.json +5 -5
package/dist/cli/index.js
CHANGED
|
@@ -34698,13 +34698,6 @@ const steps = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.definePropert
|
|
|
34698
34698
|
runCompiler,
|
|
34699
34699
|
updatePackageJson
|
|
34700
34700
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
34701
|
-
const ADAPTER_LINKS = {
|
|
34702
|
-
sveltekit: "https://inlang.com/m/dxnzrydw/paraglide-sveltekit-i18n",
|
|
34703
|
-
nextjs: "https://inlang.com/m/osslbuzt/paraglide-next-i18n",
|
|
34704
|
-
astro: "https://inlang.com/m/iljlwzfs/paraglide-astro-i18n",
|
|
34705
|
-
solidstart: "https://inlang.com/m/n860p17j/paraglide-solidstart-i18n",
|
|
34706
|
-
vite: "https://github.com/opral/monorepo/tree/main/inlang/source-code/paraglide/paraglide-vite"
|
|
34707
|
-
};
|
|
34708
34701
|
const initCommand = new Command().name("init").summary("Initializes inlang Paraglide-JS.").action(async () => {
|
|
34709
34702
|
const repoRoot = await findRepoRoot({
|
|
34710
34703
|
nodeishFs: nodeFsPromises,
|
|
@@ -34745,39 +34738,22 @@ const initCommand = new Command().name("init").summary("Initializes inlang Parag
|
|
|
34745
34738
|
telemetry.capture({ event: "PARAGLIDE-JS init finished" });
|
|
34746
34739
|
const absoluteSettingsPath = nodePath.resolve(ctx9.projectPath, "settings.json");
|
|
34747
34740
|
const relativeSettingsFilePath = absoluteSettingsPath.replace(process.cwd(), ".");
|
|
34748
|
-
|
|
34741
|
+
const successMessage = dedent`inlang Paraglide-JS has been set up sucessfully.
|
|
34749
34742
|
|
|
34750
34743
|
1. Run your install command (npm i, yarn install, etc)
|
|
34751
34744
|
2. Register all your languages in ${relativeSettingsFilePath}
|
|
34752
34745
|
3. Run the build script (npm run build, or similar.)
|
|
34753
34746
|
4. Done :) Happy paragliding 🪂
|
|
34754
34747
|
|
|
34755
|
-
`;
|
|
34756
|
-
const stackChoice = await promtStack();
|
|
34757
|
-
if (Object.keys(ADAPTER_LINKS).includes(stackChoice)) {
|
|
34758
|
-
successMessage += "\n\n";
|
|
34759
|
-
successMessage += dedent`
|
|
34760
|
-
HINT:
|
|
34761
|
-
If you are using ${stackChoice} with paraglide, you will likely also want to use
|
|
34762
|
-
|
|
34763
|
-
\`@inlang/paraglide-${stackChoice}\`
|
|
34764
|
-
|
|
34765
|
-
Read the documentation at:
|
|
34766
|
-
${ADAPTER_LINKS[stackChoice]}
|
|
34767
|
-
`;
|
|
34768
|
-
}
|
|
34769
|
-
successMessage += "\n\n";
|
|
34770
|
-
successMessage += dedent`
|
|
34771
34748
|
For questions and feedback, visit
|
|
34772
|
-
https://github.com/opral/monorepo/discussions
|
|
34773
|
-
`;
|
|
34749
|
+
https://github.com/opral/monorepo/discussions`;
|
|
34774
34750
|
ctx.logger.box(successMessage);
|
|
34775
34751
|
});
|
|
34776
34752
|
const addParaglideJsToDevDependencies = async (ctx) => {
|
|
34777
34753
|
const ctx1 = await updatePackageJson({
|
|
34778
34754
|
devDependencies: async (devDeps) => ({
|
|
34779
34755
|
...devDeps,
|
|
34780
|
-
"@inlang/paraglide-js": "1.11.
|
|
34756
|
+
"@inlang/paraglide-js": "1.11.1"
|
|
34781
34757
|
})
|
|
34782
34758
|
})(ctx);
|
|
34783
34759
|
ctx.logger.success("Added @inlang/paraglide-js to the devDependencies in package.json.");
|
|
@@ -34838,21 +34814,7 @@ const addCompileStepToPackageJSON = async (ctx) => {
|
|
|
34838
34814
|
process.exit(1);
|
|
34839
34815
|
return ctx;
|
|
34840
34816
|
};
|
|
34841
|
-
|
|
34842
|
-
return await promptSelection("Which tech stack are you using?", {
|
|
34843
|
-
options: [
|
|
34844
|
-
{ label: "Other", value: "other" },
|
|
34845
|
-
{ label: "Vanilla", value: "vanilla" },
|
|
34846
|
-
{ label: "NextJS", value: "nextjs" },
|
|
34847
|
-
{ label: "SvelteKit", value: "sveltekit" },
|
|
34848
|
-
{ label: "Astro", value: "astro" },
|
|
34849
|
-
{ label: "SolidStart", value: "solidstart" },
|
|
34850
|
-
{ label: "Vite", value: "vite" }
|
|
34851
|
-
],
|
|
34852
|
-
initial: "other"
|
|
34853
|
-
});
|
|
34854
|
-
}
|
|
34855
|
-
const cli = new Command().name("paraglide-js").addCommand(compileCommand).addCommand(initCommand).showHelpAfterError().version("1.11.0");
|
|
34817
|
+
const cli = new Command().name("paraglide-js").addCommand(compileCommand).addCommand(initCommand).showHelpAfterError().version("1.11.1");
|
|
34856
34818
|
export {
|
|
34857
34819
|
defaults as Defaults,
|
|
34858
34820
|
GitPackIndex as G,
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@inlang/paraglide-js",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "1.11.
|
|
4
|
+
"version": "1.11.1",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"publishConfig": {
|
|
7
7
|
"access": "public"
|
|
@@ -58,17 +58,17 @@
|
|
|
58
58
|
"memfs": "4.6.0",
|
|
59
59
|
"rollup": "3.29.1",
|
|
60
60
|
"typescript": "^5.5.2",
|
|
61
|
-
"vite": "4.5.2",
|
|
61
|
+
"vite": "^4.5.2",
|
|
62
62
|
"vite-plugin-dts": "^3.8.1",
|
|
63
63
|
"vite-tsconfig-paths": "^4.3.2",
|
|
64
64
|
"vitest": "0.34.3",
|
|
65
65
|
"@inlang/recommend-sherlock": "0.1.0",
|
|
66
66
|
"@inlang/recommend-ninja": "0.1.0",
|
|
67
|
+
"@inlang/language-tag": "1.5.1",
|
|
67
68
|
"@inlang/plugin-message-format": "2.2.0",
|
|
68
69
|
"@inlang/sdk": "0.36.3",
|
|
69
|
-
"@
|
|
70
|
-
"@lix-js/client": "2.2.1"
|
|
71
|
-
"@lix-js/fs": "2.2.0"
|
|
70
|
+
"@lix-js/fs": "2.2.0",
|
|
71
|
+
"@lix-js/client": "2.2.1"
|
|
72
72
|
},
|
|
73
73
|
"exports": {
|
|
74
74
|
".": {
|