Library for building tours on your front page (Step-by-step guide and feature introduction)
npm install web-story##### Library for building tours on your front page (Step-by-step guide and feature introduction).
$ npm install --save web-story
`Usage
1. Include the css file (web-story.css) in you app
2. Import the js file (index.js) in your app you can choose the way you want to import the file
`
import { WebStory } from 'webStory'
var WebStory = require('webStory')
`
3. use the WebStory to create new Story :)
`
// WebStory = WebStory.WebStory - in case imported using script tagwebStory = new WebStory({
getCurrentPageName: function () {
return "string that represent the current page that you re found";
},
pages: [
{
pageContainer: undefined, //(first page must be witout pageContainer beacasue is dont have one it is popUp)
template: "
{{test}}
" //(in case undefined there is default template)
data: {
test: "this string will be transfer with {{test}} in the template",
header:"this is prop of the deafulat template",
subHeader:"this is prop of the deafulat template"
}
},
{
pageContainer: {
cssSelector: #elementId, //css selector for get the element
position: 'left/right/top/botton // from where the tooltip will show'
},
template:undefined, //(undefined = default template),
data: {
header: "header of the default template",
content: "content of the default template"
}
}
]});webStory.startStory(); -- return Promise
``
License
----
###### MIT