@oframe/cli
v1.0.3
Published
The @oframe/cli are a small list of commands to facilitate web development.
Downloads
8
Readme
@oframe/cli
The @oframe/cli are a small list of commands to facilitate web development.
Install
Is recommended to install globally for several reasons. It supplies the o
global entry, making it simpler to type. It facilitates shared hosting for multiple projects, for example by serving the folder that stores multiple sites. It also simplifies the workflow, allowing you to quickly create new project structures with a single command.
npm i @oframe/cli -g
yarn add @oframe/cli --global
However is can also equally be installed locally. This might be useful to simplify sharing projects, or automating server setup for single-page-app-style websites.
npm i @oframe/cli -D
yarn add @oframe/cli -D
Commands
All commands are recommended to be made through the provided bin: o
.
serve
Using @oframe/server
, the serve
command creates a new http development server in the current repository.
Syntax
If installed locally, use npx
to access the bin in node_modules
:
npx o serve [port]
Else use globally:
o serve [port]
Arguments
port
An Integer
describing the desired port. Default is 8080
. If port unavailable, will incrementally search for an available one, rather than returning an error.
create
Using @oframe/templates
, the create
command creates a new project structure.
Syntax
If installed locally, use npx
to access the bin in node_modules
:
npx o create [template]
Else use globally:
o create [template]
Arguments
template
An String
for the template type.