Skip to content
This repository was archived by the owner on Sep 9, 2018. It is now read-only.

nuxt-community/module-builder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Nuxt Module Builder

npm (scoped with tag) npm Dependencies

🏗️ Nuxt Standard Module Builder

⚠️ This package is no longer maintained as Nuxt 2+ modules natively support ESM! Please use module-template

Features

  • Build modules using same tool-chain of nuxt
  • ES6 Support out of the box
  • Nuxt inspired build system using optional single nuxt.module.config.js file
  • Standard eslint rules

Using module starter template

Just head to nuxt-community/module-template to make your fresh module in few minutes.

Getting started

Edit package.json like this:

{
    "scripts": {
        "build": "nuxt-module"
    },
    "devDependencies": {
        "nuxt-module-builder": "latest"
    }
}

Create src/index.js file:

export default async function (moduleOptions) {
    // ...
}

Optionally add a moduleBuilder section in package.json or create nuxt.module.config.js in the root of module project to customize module builder:

module.exports = {
    meta: {
        name: 'myModule'
    },
    plugins: [
        // rollup plugins
    ]
}

You can now use npm run nuxt-module to generate dist/index.js

For watch mode, you can use nuxt-module --watch

ESLint

TODO

License

MIT License

Copyright (c) 2017 Nuxt.js

About

🏗️ Nuxt Standard Module Builder (Depricated)

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 2

  •  
  •