spyne-cli
is a command-line utility designed to streamline the process of generating and managing applications built using the SpyneJS framework. It simplifies the creation of ViewStream
, DomElement
, Channel
, and SpyneTrait
classes, making it easier to build scalable and modular single-page applications.
- Create a new SpyneJS application with a single command.
- Generate
ViewStream
,DomElement
,Channel
, andSpyneTrait
classes via interactive prompts. - Easily extend and customize applications.
- Built-in support for channel-driven development.
To install the spyne-cli
, you need to have Node.js and npm installed on your system.
-
Install the package globally:
npm install -g spyne-cli
To create a new SpyneJS application, run:
npx spyne-cli new <app-name>
This will generate a fully structured SpyneJS SPA in the specified <app-name>
directory.
To generate SpyneJS components, simply run:
npx spyne-cli
You’ll be presented with an interactive menu where you can select the file type:
ViewStream
DomElement
Channel
SpyneTrait
Use the arrow keys to make a selection, and follow the prompts to name and configure your file.
This interface is ideal for developers who want fast, zero-config scaffolding during development.
- Create a new application:
npx spyne-cli new my-spyne-app
- Navigate to the project and start the application:
cd my-spyne-app && npm start
- Run the interactive generator:
npx spyne-cli
- Select the file type (e.g.,
ViewStream
), and follow the prompts to generate a new component.
Contributions are welcome! Please feel free to submit a Pull Request or open an Issue on the GitHub repository.
This project is licensed under the MIT License.