Skip to content

Commit

Permalink
Doc improvement related to #129
Browse files Browse the repository at this point in the history
  • Loading branch information
thednp committed May 6, 2017
1 parent f2f0f47 commit 8329559
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
6 changes: 6 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,12 @@ var bsn = require("bootstrap.native");
var btn = new bsn.Button(element,'loading');
```

Additionally, to use V4, you can do the following:
```
var bsn = require('bootstrap.native/dist/bootstrap-native-v4');
var btn = new bsn.Button(element,'loading');
```

**Note:** If you are working in a virtual browser environment (i.e. running front-end tests in NodeJS), `bootstrap.native` requires both `window` and `document` to be in scope. You will need to use a mock browser.


Expand Down
6 changes: 4 additions & 2 deletions v4.html
Original file line number Diff line number Diff line change
Expand Up @@ -153,8 +153,10 @@ <h3>npm/Bower</h3>
$ bower install --save bootstrap.native
</code></pre></div>

<p>In order to be able to use V4, after you have installed the package you need to edit the <code>bower.json</code> and/or <code>package.json</code> to use the V4 as main file: </p>
<div class="highlight"><pre><code class="language-javascript" data-lang="javascript">"main": "dist/bootstrap-native-v4.js",</code></pre></div>
<p>In order to be able to use V4, after you have installed the package you can do the following: </p>
<div class="highlight"><pre><code class="language-javascript" data-lang="javascript">var bsn = require('bootstrap.native/dist/bootstrap-native-v4');
var btn = new bsn.Button(element, 'text');
</code></pre></div>

<h1>Examples</h1>
<h2>Alert</h2>
Expand Down

0 comments on commit 8329559

Please sign in to comment.