Package Exports
- quasar-json-api
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (quasar-json-api) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
quasar-json-api
Description
The quasar-json-api
is a library to normalize and validate your JSON Api for a Quasar Component, Directive, Mixin or Plugin.
The output of the results will be placed in the dist/api folder.
Usage
Before proceeding, make sure you are using the Quasar build system from the UI kit.
$ yarn add --dev quasar-json-api
In your build
folder, create a file called: build.api.js
Add the following to it:
const path = require('path')
global.rootDir = path.resolve(__dirname, '..')
global.distDir = path.resolve(__dirname, '../dist')
require('quasar-json-api')()
In your build/index.js
find the createFolder('dist')
command and modify as follows:
createFolder('dist')
createFolder('dist/api')
In your build/script.javascript.js
find the build(builds)
command and modify as follows:
build(builds)
.then(() => {
require('./build.api')
})
That's it!
When you build your Component or Directive via yarn build
(from your UI kit templated package), your JSON API will be Normalized and Validated and the output will be placed in the dist/api
folder.
JSON API
TODO
Donate
If you appreciate the work that went into this, please consider donating to Quasar or Jeff.
License
MIT (c) Jeff Galbraith jeff@quasar.dev