Code Monkey home page Code Monkey logo

aimer's Introduction

Aimer

NPM version NPM downloads Build Status donate chat

The UI Development Framework, it's so simple that you'll fall in love with.

Install

yarn add aimer --dev

How to use

Assume you have a component Button.vue and you wanna demonstrate it:

import Aimer from 'aimer'
import 'aimer/dist/aimer.css'

// And the button you wanna demonstrate
import MyButton from './path/to/Button.vue'

const aimer = new Aimer({
  title: 'optional header title'
})

aimer.add({
  title: 'With text',
  component: {
    template: '<my-button>hello world</my-button>',
    components: {
      MyButton
    }
  },
  readme: '<p>some html</p>',
  example: '...some example code'
})

aimer.add({
  title: 'With emoji',
  component: {
    template: '<my-button>๐Ÿ˜„๐ŸŽ‰๐Ÿ˜Ž๐Ÿ‘ป</my-button>',
    components: {
      MyButton
    }
  }
})

// Start Aimer instance at given node
aimer.start('#app')

Run this script with your favoite bundler of choice, maybe webpack? And you can preview it in the browser:

preview

See it in action. ๐Ÿš€

Work with other frameworks

Examples

API

new Aimer([options])

options

title

Default: <Aimer Logo>
Type: string

Header title.

Adapter

Default: AimerVue

Aimer adapter, check out the default one for reference.

github

Type: string

GitHub repo slug or URL.

twitter

Type: string

Twitter handle or URL.

aimer.add(story)

story

title

Type: string
Required: true

Story title.

component

Type: any
Required: true

The component.

example

Type: string

Example code.

readme

Type: HTMLString

Use as README.

License

MIT ยฉ EGOIST

aimer's People

Contributors

egoist avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.