getflywheel / create-local-addon Goto Github PK
View Code? Open in Web Editor NEWA generator to assist in the development of new Local add-ons. Generates a basic add-on to act as a starting point for development.
A generator to assist in the development of new Local add-ons. Generates a basic add-on to act as a starting point for development.
Here is the output I'm seeing after running npx create-local-addon
and answering the initial prompts.
Using Node v18.16.0
Need to install the following packages:
[email protected]
Ok to proceed? (y)
npm WARN deprecated [email protected]: See https://github.com/lydell/source-map-url#deprecated
npm WARN deprecated [email protected]: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated [email protected]: this library is no longer supported
npm WARN deprecated [email protected]: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated [email protected]: See https://github.com/lydell/source-map-resolve#deprecated
npm WARN deprecated [email protected]: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated [email protected]: request has been deprecated, see https://github.com/request/request/issues/3142
? May Local Add-on Creator anonymously report usage statistics to improve our tool over time? We will not collect any personal information about you or your add-on — only the way you use this tool. No
Hello! We are here today to create a new add-on for the Local application. Yay!
We are planning to pull down a basic add-on –– just a little something to act as a starting point for your add-on development.
Then we'll do some basic setup: put your files where you want them, make sure Local knows about your add-on, and get you up and running as soon as possible!
You can customize the setup a bit if you want! Run create-local-addon --help to learn more.
Okay, let's get started!
? What is the name of your addon? This will be shown to users. symlinked-plugin-development
? We would like to make a directory for your add-on. What would you like to name this directory? symlinked-plugin-development
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: [email protected]
npm ERR! Found: [email protected]
npm ERR! node_modules/eslint
npm ERR! dev eslint@"^8.50.0" from the root project
npm ERR! peer eslint@">= 4.12.1" from [email protected]
npm ERR! node_modules/babel-eslint
npm ERR! dev babel-eslint@"^10.1.0" from the root project
npm ERR! peer babel-eslint@"^10.0.1" from @getflywheel/[email protected]
npm ERR! node_modules/@getflywheel/eslint-config-local
npm ERR! dev @getflywheel/eslint-config-local@"1.0.4" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer eslint@"^5.0.0" from @getflywheel/[email protected]
npm ERR! node_modules/@getflywheel/eslint-config-local
npm ERR! dev @getflywheel/eslint-config-local@"1.0.4" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR!
npm ERR! For a full report see:
npm ERR! /Users/joe.fusco/.npm/_logs/2023-10-13T14_35_09_035Z-eresolve-report.txt
npm ERR! A complete log of this run can be found in:
npm ERR! /Users/joe.fusco/.npm/_logs/2023-10-13T14_35_09_035Z-debug-0.log
> [email protected] build
> tsc
sh: tsc: command not found
NEXT STEPS
If Local is already running, you will need to restart the application in order for your add-on to appear.
Making changes to your add-on:
→ A symlink pointing to your add-on directory has been made in the Local add-ons directory:
/Users/joe.fusco/Library/Application Support/Local/addons/symlinked-plugin-development
→ You can change your add-on by making changes to the source files:
/Users/joe.fusco/Code/symlinked-plugin-development/src
(Boilerplate.jsx and renderer.jsx will have some basic logic in them to give you a starting point, but you'll probably want to make some changes.)
→ Compile, watch add-on source files, and trigger recompilation on change:
cd /Users/joe.fusco/Code/symlinked-plugin-development
npm run build --watch
(You can leave the --watch flag off if you just want to compile your changes once.)
NEED SOME HELP?
→ Looking for resources to help you get started with your add-on? Visit https://localwp.com/get-involved
→ Thinking of submiting your add-on to the Local add-on marketplace? Visit https://localwp.com/submit-addon
Okay, we'll get out of the way and let you start developing! If you have any questions or concerns, try consulting the documentation for Local add-on development.
When running in non-interactive mode, for example, like this:
npx create-local-addon "My Product Name" directory-name
The productname
argument isn't correctly parsed, with the second word of the string being interpreted as the directory name. See this screenshot for more details:
Note: Running the command in interactive mode (ie, when create-local-addon
prompts you for productname
and directoryname
) does work.
Ever since I updated to Windows 11, I keep getting these errors in the console. I am actually seeing the errors for other add-ons as well. When I disable the add-ons, the number of errors in the console lessen.
C:\Program Files (x86)\Local\resources\app.asar\node_modules@sentry\utils\dist\instrument.js:111 Error: Invalid package C:\C:\Program Files (x86)\Local\resources\app.asar
at createError (node:electron/js2c/asar_bundle:2:1608)
at Object. (node:electron/js2c/asar_bundle:2:4940)
at C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:1:31946
at t.default (C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:1:32039)
at 1920 (C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:1:297170)
at n (C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:1:341977)
at C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:1:342417
at Object. (C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:1:342443)
at Object. (C:\Program Files (x86)\Local\resources\app.asar\node_modules@getflywheel\local-components\dist\index.js:3:3)
at Module._compile (node:internal/modules/cjs/loader:1269:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1324:10)
at Module.load (node:internal/modules/cjs/loader:1124:32)
at Module._load (node:internal/modules/cjs/loader:965:12)
at f._load (node:electron/js2c/asar_bundle:2:13377)
at o._load (node:electron/js2c/renderer_init:2:3109)
at Module.require (node:internal/modules/cjs/loader:1148:19)
at require (node:internal/modules/cjs/helpers:110:18)
at 9381 (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:173643)
at r (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:340139)
at 60653 (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:2:1772243)
at r (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:340139)
at 98123 (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:2:1770147)
at r (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:340139)
at 31492 (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:2:1735844)
at r (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:340139)
at 31933 (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:2:1622630)
at r (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:340139)
at C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:341317
at Object. (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:201:341344)
at Object. (C:\Program Files (x86)\Local\resources\app.asar\api\renderer-bundle.js:203:3)
at Module._compile (node:internal/modules/cjs/loader:1269:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1324:10)
at Module.load (node:internal/modules/cjs/loader:1124:32)
at Module._load (node:internal/modules/cjs/loader:965:12)
at f._load (node:electron/js2c/asar_bundle:2:13377)
at o._load (node:electron/js2c/renderer_init:2:3109)
at Module.require (node:internal/modules/cjs/loader:1148:19)
at require (node:internal/modules/cjs/helpers:110:18)
at 51655 (file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:288:487131)
at webpack_require (file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:288:901717)
at 63733 (file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:2:2328184)
at webpack_require (file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:288:901717)
at 45234 (file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:2:2331070)
at webpack_require (file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:288:901717)
at file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:288:903337
at file:///C:/Program%20Files%20(x86)/Local/resources/app.asar/renderer/_browserWindows/app/app.js:288:903422
(anonymous) @ C:\Program Files (x86)\Local\resources\app.asar\node_modules@sentry\utils\dist\instrument.js:111
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.