From b66ce43928c2a2f2222c0a5aa18c4e930bd9abfb Mon Sep 17 00:00:00 2001 From: Mason Payne Date: Sun, 23 Feb 2025 00:00:39 -0700 Subject: [PATCH] add a readme --- readme.md | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 readme.md diff --git a/readme.md b/readme.md new file mode 100644 index 0000000..fa07eed --- /dev/null +++ b/readme.md @@ -0,0 +1,10 @@ +# How this script works + +1. It creates the project folder, initializes npm, and installs Vue version 3 (instead of vue@next) along with TypeScript, Vite, and the Vue plugin. +2. It creates a src folder with a sample Vue component (MyComponent.vue) and an entry file (index.ts) that registers and exports the component. +3. It sets up the TypeScript configuration (tsconfig.json) including declaration file generation. +4. It creates a Vite configuration file (vite.config.ts) set up for building a library (producing both ES and UMD formats) with Vue declared as external. +5. It uses a small Node.js script (update-package.js) to modify the package.json file—adding build scripts and specifying main, module, and typings—thus avoiding dependencies on the jq command. +6. It creates a basic README for usage instructions. + +After running this script, you’ll have a project ready for you to add your component(s). You can run "npm run build" to generate distributable files into the dist folder and then publish your package as desired. \ No newline at end of file