@inspr/diode
Inspr's TypeScript bundler and optimizer
Last updated 13 days ago by aluchianik .
MIT · Repository · Original npm · Tarball · package.json
$ cnpm install @inspr/diode 
SYNC missed versions from official npm registry.

Diode

Diode

A bundler free of issues

Installation

Install diode cli in your project with npm or yarn:

npm install @inspr/diode
yarn add @inspr/diode

or globally to use Diode from anywhere:

npm -g install @inspr/diode
yarn global add @inspr/diode

Quick Start

Create fresh project

diode init AwesomeProject 

Diode will create new folder AwesomeProject with preconfigured diode.yaml (config), babel, jest, typescript. diode.yaml config:

version: 0.0.0
workspaces:
  main: 
    context: packages 
    description: This is an example project for diode
    private: true 
  • version: version in root package.json
  • workspaces: every workspace it's a folder where would be packages for bundling, workspaces can be more than one
  • main: workspace name to address it in cli commands
  • context: path to packages folder relative to root (where is diode.yaml)
  • description: description
  • private: boolean - it's private package or not

After creating project lets enter our new created folder/project AwesomeProject and start creating packages in it. First of all we need to install dependencies:

    cd AwesomeProject
    yarn install OR npm install
    diode new project1

Diode will create new folder under workspaces.main.context path with provided name project1. In this folder also be created configured package.json, tsconfig.json files and src/index.ts file as entry point. If you want to create one more package just use diode new [name] from root of project. After this steps you can start developing, to build your project use diode build [packageName?] - if packageName is not provided Diode will build all packages for all workspaces, to build only some of them provide packagesNames(actual package package.json name property e.g project1) comma separated. Or use diode watch [packageName?] to rebuild files on changes.

Commands

diode init <projectName> --template? [-t]

Initializes new project. --template creates new project from `diode.yaml config.

diode new <libName> [workspace?]

Creates new library in the workspaces folder that is configured in diode .yaml config under workspaces.[name].context field, already preconfigured for the project. If workspace is not provided Diode will take first workspace from config.

diode build <libName?>

Builds your libraries by creating bundles and generating TS types definition files. Libraries names can be provided space separated. If no arguments is provide Build runs across all libraries from you diode.yaml context field.

didoe watch <libName?>

Run Build across projects provided space separated (if no arguments - across all projects). After that watches for changes in libraries files and rebuilds if needed.

diode clean <libName?>

Removes artifacts that diode has generated in the past.

diode list

Outputs the list of packages found in the project with their `package.json files and one object of their dependencies.

diode run <libName> [file]

Runs diode build <libName> then evaluates [file] from this libName with Node

diode sync

Merges dependencies across all libraries from diode.yaml context field by replacing to highest version found from all libraries.

Current Tags

  • 0.1.4                                ...           latest (13 days ago)

34 Versions

  • 0.1.4                                ...           13 days ago
  • 0.1.3                                ...           a month ago
  • 0.1.2                                ...           a month ago
  • 0.1.1                                ...           a month ago
  • 0.1.0                                ...           a month ago
  • 0.0.30                                ...           a month ago
  • 0.0.29                                ...           a month ago
  • 0.0.28                                ...           a month ago
  • 0.0.27                                ...           a month ago
  • 0.0.26                                ...           a month ago
  • 0.0.25                                ...           a month ago
  • 0.0.24                                ...           a month ago
  • 0.0.23                                ...           a month ago
  • 0.0.22                                ...           a month ago
  • 0.0.21                                ...           a month ago
  • 0.0.20                                ...           a month ago
  • 0.0.19                                ...           a month ago
  • 0.0.18                                ...           a month ago
  • 0.0.17                                ...           a month ago
  • 0.0.15                                ...           a month ago
  • 0.0.14                                ...           a month ago
  • 0.0.13                                ...           a month ago
  • 0.0.12                                ...           2 months ago
  • 0.0.11                                ...           2 months ago
  • 0.0.10                                ...           2 months ago
  • 0.0.9                                ...           2 months ago
  • 0.0.8                                ...           2 months ago
  • 0.0.7                                ...           2 months ago
  • 0.0.6                                ...           2 months ago
  • 0.0.5                                ...           2 months ago
  • 0.0.4                                ...           2 months ago
  • 0.0.3                                ...           2 months ago
  • 0.0.2                                ...           2 months ago
  • 0.0.1                                ...           2 months ago
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 71
Dependents (1)

Copyright 2014 - 2016 © taobao.org |