1.1.0 • Published 3 years ago
@croudtech/cc-v3-base v1.1.0
CC-V3-Base
Installation
Install the scoped package via the command line
yarn add @croudtech/cc-v3-base
Components
A La Carte Menu
You can globally add a selection of the components by using the aLaCarte module in your nuxt.config.js
Option | Description | Default |
---|---|---|
components | Array of components that you wish to add to the global scope of your project | [] |
prefix | Add a prefix to all global components above | '' |
// nuxt.config.js
modules: [
[
"@croudtech/cc-v3-base/modules/aLaCarte",
{
components: ["FormBuilder", "Slider", "Reveal", "Scheduler"],
prefix: "Base" // optional
}
]
];
You can now use any of these in the template of your components
<!-- no prefix -->
<form-builder></form-builder>
<!-- prefix: 'Base' -->
<base-form-builder></base-form-builder>
Manual
The components can also be individually imported into your components with the following technique.
// MyComponent.vue
import FormBuilder from "@croudtech/cc-v3-base/components/FormBuilder";
export default {
components: {
FormBuilder
}
};