README
Javascript SDK — SMIT. Store
Core Features
- Fetch all categories, facets and products
- ...
- ...
- ...
Supported browsers
- Chrome
- Firefox
- Edge
- Safari
Getting started
...
<script src="//cdn.smit.store/dist/{{ version }}/sdk.js?api={{ apiKey }}"></script>
Recommedations
Add the following to first lines within your document head:
<link rel="preconnect" href="https://api.smit.store" />
<link rel="preconnect" href="https://cdn.smit.store" />
The following can serve as fallback:
<link rel="dns-prefetch" href="https://api.smit.store" />
<link rel="dns-prefetch" href="https://cdn.smit.store" />
Installation
...
npm install --save @smitnet/smit-store-sdk
Configuration
<script type="text/javascript">
var SomeNameForSDK = window.SmitStore.Build({
// configuration options
})
SomeNameForSDK.Products.All().then(function(data) { /* do something with `data` */ })
<script>
Documentation and references
...
Rollup instead of webpack
The bundlers syntax-wise the same, but under the hood please read The Why on rollupjs.org.
License
This repository is published under MIT.
Contribution
Development
To start a new version:
npm version patch && npm run build
To start the LiveReload version you can use:
npm run start