Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat/cli/react multitenancy #131

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

ConzorKingKong
Copy link

Summary of change

Updates React multitenancy upgrades to be boilerplate

Test plan

  • If added a new boilerplate
    • I tested the new boilerplate by running the CLI locally
    • I tested that the boilerplate is created and works correctly when using command line flags (--recipe=... for example)
  • If added a new recipe, frontend or backend
    • I tested that the newly added option is usable by passing command line flags (--recipe=... for example)

Checklist for important updates

  • Changelog has been updated
  • Changes to the version if needed
    • In package.json
    • In package-lock.json
    • In lib/ts/version.ts
  • Had run npm run build-pretty
  • Had installed and ran the pre-commit hook
  • If added a new recipe, I also modified types to include the new recipe in Recipe and allRecipes
  • If added a new frontend, I also modified types to include the new frontend in SupportedFrontends and allFrontends if required
  • If added a new backend, I also modified types to include the new backend in SupportedBackends and allBackends if required

Remaining TODOs for this PR

  • Make project work after boilerplate folder rename

@ConzorKingKong
Copy link
Author

ConzorKingKong commented Dec 15, 2024

Hey! So I have this basically ready to rock. One small problem — I changed the name of the folder supertokens-react-multitenancy to react-multitenancy and it is blowing up the generation. I can't figure out why. I updated the folder name inside of the lib/ts/config.ts and pretty built, but it isn't working. I get two different errors depending on how I run it.

Running npx create-supertokens-app --branch=feat/cli/react-multitenancy doesn't work - forces version 0.0.55 and gives this error:

Error: Error: ENOENT: no such file or directory, rename '/Users/connor/projects/supertokens/tools/f/supertokens-react-multitenancy' -> '/Users/connor/projects/supertokens/tools/f/frontend'
  at Object.renameSync (node:fs:1032:11)
  at setupFrontendBackendApp (file:///Users/connor/.npm/_npx/f43f4c5b1dac493a/node_modules/create-supertokens-app/lib/build/utils.js:241:8)
  at setupProject (file:///Users/connor/.npm/_npx/f43f4c5b1dac493a/node_modules/create-supertokens-app/lib/build/utils.js:517:15)
  at run (file:///Users/connor/.npm/_npx/f43f4c5b1dac493a/node_modules/create-supertokens-app/lib/build/index.js:175:19)
  at process.processTicksAndRejections (node:internal/process/task_queues:95:5)


Error: If you think this is an issue with the tool, please report this as an issue at https://github.com/supertokens/create-supertokens-app/issues

Running locally with npx . Gives version 0.0.57 (version I set) and gives this error instead:

Error: Error: ENOENT: no such file or directory, rename '/Users/connor/projects/supertokens/create-supertokens-app/testmulti/react-multitenancy' -> '/Users/connor/projects/supertokens/create-supertokens-app/testmulti/frontend'
  at Object.renameSync (node:fs:1032:11)
  at setupFrontendBackendApp (file:///Users/connor/projects/supertokens/create-supertokens-app/lib/build/utils.js:241:8)
  at setupProject (file:///Users/connor/projects/supertokens/create-supertokens-app/lib/build/utils.js:517:15)
  at run (file:///Users/connor/projects/supertokens/create-supertokens-app/lib/build/index.js:175:19)
  at process.processTicksAndRejections (node:internal/process/task_queues:95:5)


Error: If you think this is an issue with the tool, please report this as an issue at https://github.com/supertokens/create-supertokens-app/issues

Do you have any insight from changing the folder name in the previous react upgrade?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant