glarce-combodeprecated

Merges multiple js files into one. Similar to Sass.

Usage no npm install needed!

<script type="module">
  import glarceCombo from 'https://cdn.skypack.dev/glarce-combo';
</script>

README

Combo.js

Combo.js is a tool that we hope will make it easier to write javascript programs. It is writen in Node.js but we hope to move it to other languages as well.

Installation

Because we are using node we will be using npm to do it quickly. Run this in your terminal:

npm install glarce-combo --save-dev

Usage

There is no watch function yet but we hope to add that in a future relese.

To initialase it please run:

const combine = require('glarce-combo');

var merge = new combine({
    "import": "src/js/",
    "export": "dist/js/"
});

The JSON passed in includes the settings. import specifes the source directory and export specifies the output directory.

To run the combining execute the folowing:

merge.start();

File syntax

The file syntax is easy.

Importing

@import "<file>";

Rules:

  • Must use "" not ''
  • Must have a ;
  • Does not support ../. If you want this please write a pull request with the code

Dev

Please read this article.