@highbeek/create-rnstarterkit 1.0.2-beta.14 → 1.0.2-beta.15

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/README.md CHANGED
@@ -230,7 +230,7 @@ Templates live in `src/templates/`. Generator logic is in `src/generators/appGen
230
230
 
231
231
  ## Status
232
232
 
233
- Current version: `1.0.2-beta.13`
233
+ Current version: `1.0.2-beta.15`
234
234
 
235
235
  Beta release — core scaffolding, presets, and generators are working. Feedback and contributions welcome.
236
236
 
@@ -235,7 +235,7 @@ const program = new commander_1.Command();
235
235
  program
236
236
  .name("create-rnstarterkit")
237
237
  .description("Scaffold a production-ready React Native app")
238
- .version("1.0.2-beta.12")
238
+ .version("1.0.2-beta.15")
239
239
  .argument("[projectName]", "Name of the project (alphanumeric)")
240
240
  .option("--preset <name>", "Skip prompts with a preset: minimal | fintech | social | indie")
241
241
  .action(async (projectName, cmdOptions) => {
@@ -246,16 +246,19 @@ async function createStandardStructure(targetPath, platform, state) {
246
246
  "hooks",
247
247
  "utils",
248
248
  "services",
249
- "api",
250
249
  "config",
251
250
  "theme",
252
- "providers",
253
251
  "types",
254
252
  ];
255
- // Only scaffold a context/ dir when Context API is the chosen state solution
253
+ // context/ only when Context API is the state solution
256
254
  if (state === "Context API" || state === "None") {
257
255
  commonDirectories.push("context");
258
256
  }
257
+ // api/ only when an API client or auth module will populate it
258
+ // (auth modules and apiClient copyOptionalModule both write into api/)
259
+ // — handled by those modules; we don't pre-create an empty dir here
260
+ // providers/ is NOT pre-created — writeIfMissing creates it on demand
261
+ // when SWR / React Query / i18n providers are written into it
259
262
  const cliOnlyDirectories = ["navigation", "screens"];
260
263
  const directories = platform === "Expo"
261
264
  ? commonDirectories
@@ -2032,7 +2035,7 @@ async function configureTsconfigAlias(targetPath, absoluteImports) {
2032
2035
  if (absoluteImports) {
2033
2036
  tsconfig.compilerOptions.baseUrl = ".";
2034
2037
  tsconfig.compilerOptions.paths = tsconfig.compilerOptions.paths || {};
2035
- tsconfig.compilerOptions.paths["@/*"] = ["./*"];
2038
+ tsconfig.compilerOptions.paths["@/*"] = ["./src/*"];
2036
2039
  }
2037
2040
  else if (tsconfig.compilerOptions.paths) {
2038
2041
  delete tsconfig.compilerOptions.paths["@/*"];
@@ -2050,7 +2053,7 @@ async function writeCliBabelConfig(targetPath, options) {
2050
2053
  if (options.useDotenv)
2051
2054
  plugins.push("'module:react-native-dotenv'");
2052
2055
  if (options.useAbsoluteImports) {
2053
- plugins.push("['module-resolver', { root: ['./'], alias: { '@': './' } }]");
2056
+ plugins.push("['module-resolver', { root: ['./src'], alias: { '@': './src' } }]");
2054
2057
  }
2055
2058
  const pluginsLine = plugins.length > 0 ? `,\n plugins: [${plugins.join(", ")}]` : "";
2056
2059
  const content = `module.exports = {\n presets: ['module:@react-native/babel-preset']${pluginsLine},\n};\n`;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@highbeek/create-rnstarterkit",
3
- "version": "1.0.2-beta.14",
3
+ "version": "1.0.2-beta.15",
4
4
  "description": "CLI to scaffold production-ready React Native app structures.",
5
5
  "main": "dist/src/generators/appGenerator.js",
6
6
  "bin": {