Skip to content

natoehv/nuxt-podium-module

Repository files navigation

nuxt-podium-module

npm version npm downloads Github Actions CI License semantic-release

Features

  • Zero configuration
  • Hot reload support
  • Sandbox to manage events

Quick Setup

  1. Add nuxt-podium-module dependency to your project:
#using yarn
yarn add --dev nuxt-podium-module
# using npm
npm install --save-dev nuxt-podium-module

Configure

Then, add nuxt-podium-module section in nuxt.config.js:

export default {
  nuxt-podium-module: {
    // Options
  }
}

Options

| Option | type | default | description |----------------|---|---|---|---| | podletOptions | | {} | used to add the podlet options, to more information you can read the podium-lib documentation here | | sandbox | boolean, SandboxOption | false | used to simulate events into your app |

podletOptions

Option type default description
name string 'generic' used to name the application
version string '0.0.0' version of your app
pathname string '/' path of your app
manifest string '/manifest.json' path to get manifest of your app
development boolean false used to deploy app in mode development

podlet option example:

podletOptions: {
  name: 'myPodletName', // required
  version: '1.0.0', // required
  pathname: '/', // required
  manifest: '/manifest.json', // optional
  development: true, // optional, defaults to false
},

Sandbox Options

Option type default description
events array of events [] used to give initial events

sandbox option example:

sandbox: {
  events: [
    {
      channel: 'fe-section-header',
      topic: 'auth',
      payload: {
        user: {
          name: 'User Test 2',
        }
      }
    }
  ]
}

Development

  1. Clone this repository
  2. Install dependencies using yarn install
  3. Start storybook server using yarn dev

License

MIT License

Copyright (c)

About

Nuxt module used to implement podium podlets

Topics

Resources

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •