Add create-veil-app CLI scaffolder#348
Open
Kingvic300 wants to merge 1 commit into
Open
Conversation
npx create-veil-app fetches a template (Next.js, Vite, or vanilla JS) and the sdk/ package via degit, vendors the SDK locally since it isn't published to npm yet, rewrites the file: dependency paths, and builds and installs everything so the new project runs immediately. Also carries the sdk/ dist-output fix from Miracle656#346 (tsc nests src/ output under dist/src/ instead of dist/, breaking package.json's main entry) since the scaffolded apps depend on it to build correctly.
|
@Kingvic300 is attempting to deploy a commit to the miracle656's projects Team on Vercel. A member of the Team first needs to authorize it. |
|
@Kingvic300 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #340
Summary
packages/create-veil-app/— a CLI scaffolder (npx create-veil-app my-app) that prompts for a project name and template (Next.js, Vite + React, or vanilla JS), fetches the chosenexamples/template viadegit, and produces a working, installed project.degits thesdk/package alongside the template, rewrites the template'sfile:../../sdkdependency tofile:./sdk, and builds it locally — rather than leaving the user with a broken install.tsconfig.json(e.g. Next.js), addssdktoexclude— otherwise the app's TS compiler sweeps up the SDK's raw source via**/*.tsand type-checks it against the app's (older) target, which fails on the SDK's ES2020 BigInt literals.sdk/dist-output fix from Add Electron desktop wallet example (#341) #346 (tscnestssrc/output underdist/src/instead ofdist/, sopackage.json'smain: "dist/index.js"never resolves) since every scaffolded app depends on it to build. If Add Electron desktop wallet example (#341) #346 merges first this will be a no-op overlap; if this merges first, Add Electron desktop wallet example (#341) #346 still applies cleanly.Test plan
vitetemplate: scaffolded, vendored SDK built,npm run build(renderer) succeeds,vitedev server boots and servessrc/main.tsxnexttemplate: scaffolded, vendored SDK built,next buildsucceeds (including thetsconfig.jsonexclude fix — first attempt without it failed onsdk/src/sep7.ts's BigInt literal)vanillatemplate: scaffolded,index.html's SDK import path rewritten to./sdk/dist/vanilla.js--templatevalue