Socket
Socket
Sign inDemoInstall

@originjs/cli-service

Package Overview
Dependencies
167
Maintainers
5
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @originjs/cli-service

CLI for creating server and provides commands to control it.


Version published
Maintainers
5
Install size
24.6 MB
Created

Readme

Source

cli-service

CLI for creating server and provides commands to control it.

Usage

const cliService = require('cli-service');
cliService.run('dev', 'yourProjectPath');
cliService.run('build', 'yourProjectPath');

APIs

run

async function run(name: 'dev' | 'build', execPath?: string)

Execute the commands. It receives name and optional execPath as parameters with no returns. The name of command can be dev or build.

dev

async function (execPath?: string): Promise<ViteDevServer | null>

Read your configuration to create a dev server and listen to that port. It receives optional execPath as parameter and returns ViteDevServer asynchronously. If it failed to create a vite dev server, this function returns null.

build

async function (execPath?: string): Promise<void>

Read your configuration to build the project. It receives optional execPath as parameter with no returns.

FAQs

Last updated on 09 Oct 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc