1.0.7 • Published 4 years ago

simple-file-bundler v1.0.7

Weekly downloads
1
License
ISC
Repository
-
Last release
4 years ago

Simple file bundler

The easiest way to merge files into bundles using a single command

Page in npm

How to install

npm i simple-file-bundler

How to configure

To work, you need to create a configuration file simple-file-bundle.config.js in the root of the project. This file should export an array of settings, just as in the example

module.exports = [
    {
        prefix: __dirname,
        endpoint: 'dist/style.bundle.css',
        files: [
            'src/style1.css',
            'src/style2.css',
            'src/style3.css'
        ]
    },
    {
        prefix: __dirname,
        endpoint: 'dist/scripts.js',
        files: [
            'src/index.js',
            'src/superScript.js'
        ],
        separator: '\n'
    }
];

Each setting is an object with 4 fields.

  • prefix - prefix that is assigned to all files and endpoint
  • endpoint - file to merge files into
  • files - list of files for combining them
  • separator (optional field) - a line that separates between files. The default is \n

How to use

You need to enter the console npx create-bundles

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago