frogkit
Smartfrog UI Components Library
Installation
using yarn
yarn add @smartfrog/frogkit
using npm
npm i -S @smartfrog/frogkit
Usage
component are availabale under src/component
folder
use a global component
import button from '@smartfrog/frogkit/src/components/button'
Vue.component(button.name, button)
use a component when it's needed
import button from '@smartfrog/frogkit/src/components/button'
export default {
name: 'Example',
components: { button },
}
icons
- place SVG files inside
src/assets/icons
NOTE: make sure that the SVG file contain viewBox attribute
- run
yarn icon
the script will optimise the SVG and generate an icon component for it
social icons
-
place a social icon SVG file inside
src/assets/social/base
-
run
yarn social-icon
the script will update the social icons sprite (image and css) adding the new one
Contribution
-
Fork the repo
-
install dependencies
yarn
- Start the storybook
yarn storybook
-
Build component
-
Add Story for it
-
Cover it with test
-
Make sure that the test is passing
yarn test
- Open a PR!
Semantic Release
We use semantic release now to control the version and to publish to npm registry.
According to the commit message we decide what the next version would be.
Please check the following table:
Commit message | Update |
---|---|
feat | Major |
fix | Minor |
docs | Patch |
style | Patch |
refactor | Minor |
perf | Patch |
test | Patch |
build | Patch |
ci | Patch |
chore | Patch |
revert | Minor |
Happy Coding!