1
0
mirror of https://github.com/lancedikson/bowser synced 2024-10-27 20:34:22 +00:00

Update README.md

This commit is contained in:
Denis Demchenko 2018-07-17 19:27:21 +03:00
parent bdd75028e5
commit 718bea0016

View File

@ -111,10 +111,11 @@ Thus, you can define OS or platform specific rules and they will have more prior
More of API and possibilities you will find in the `docs` folder.
# Advanced Usage
By default, `require('bowser')` requires the pre-compiled file, which can
include useless for you polyfills. In case you don't need that, you can choose
using source file requiring bowser like that: `require('bowser/src/bowser`);
Then you get ES2015 file, which is not precompiled and can be easier to debug.
By default, `require('bowser')` requires the *ES6 version of files*, which
**don't** include any polyfills. In case if you don't use your own `babel-polyfill`
you may need to have pre-built bundle with all needed polyfills.
It's possible requiring bowser like that: `require('bowser/compiled');`
As result you get a ES5 file with `babel-polyfill` bundled in it.
# Contributing
If you'd like to contribute a change to bowser, modify the files in `src/`, then run the following (you'll need node + npm installed):