mirror of
https://github.com/locomotivemtl/locomotive-boilerplate.git
synced 2026-01-15 00:55:08 +08:00
Change loco-scroll version in package.json and add uppercase to import, add forEach to polyfill
This commit is contained in:
@@ -185,9 +185,9 @@ this.load = new modularLoad({
|
||||
</div>
|
||||
```
|
||||
```js
|
||||
import locomotiveScroll from 'locomotive-scroll';
|
||||
import LocomotiveScroll from 'locomotive-scroll';
|
||||
|
||||
this.scroll = new locomotiveScroll({
|
||||
this.scroll = new LocomotiveScroll({
|
||||
el: this.el,
|
||||
smooth: true
|
||||
});
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
import { module } from 'modujs';
|
||||
import locomotiveScroll from 'locomotive-scroll';
|
||||
import LocomotiveScroll from 'locomotive-scroll';
|
||||
|
||||
export default class extends module {
|
||||
constructor(m) {
|
||||
@@ -7,7 +7,7 @@ export default class extends module {
|
||||
}
|
||||
|
||||
init() {
|
||||
this.scroll = new locomotiveScroll({
|
||||
this.scroll = new LocomotiveScroll({
|
||||
el: this.el,
|
||||
smooth: true
|
||||
});
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
"version": "1.0.0",
|
||||
"author": "Locomotive <info@locomotive.ca>",
|
||||
"dependencies": {
|
||||
"locomotive-scroll": "github:locomotivemtl/locomotive-scroll#v2",
|
||||
"locomotive-scroll": "*",
|
||||
"modujs": "*",
|
||||
"modularload": "*",
|
||||
"normalize.css": "*",
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
</div>
|
||||
|
||||
<script nomodule src="https://cdnjs.cloudflare.com/ajax/libs/babel-polyfill/7.4.4/polyfill.min.js" crossorigin="anonymous"></script>
|
||||
<script nomodule src="https://polyfill.io/v3/polyfill.min.js?features=fetch%2CCustomEvent%2CElement.prototype.matches" crossorigin="anonymous"></script>
|
||||
<script nomodule src="https://polyfill.io/v3/polyfill.min.js?features=fetch%2CCustomEvent%2CElement.prototype.matches%2NodeList.prototype.forEach" crossorigin="anonymous"></script>
|
||||
<script nomodule src="assets/scripts/abortcontroller-polyfill-only.js"></script>
|
||||
|
||||
<script src="assets/scripts/vendors.js"></script>
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
</div>
|
||||
|
||||
<script nomodule src="https://cdnjs.cloudflare.com/ajax/libs/babel-polyfill/7.4.4/polyfill.min.js" crossorigin="anonymous"></script>
|
||||
<script nomodule src="https://polyfill.io/v3/polyfill.min.js?features=fetch%2CCustomEvent%2CElement.prototype.matches" crossorigin="anonymous"></script>
|
||||
<script nomodule src="https://polyfill.io/v3/polyfill.min.js?features=fetch%2CCustomEvent%2CElement.prototype.matches%2NodeList.prototype.forEach" crossorigin="anonymous"></script>
|
||||
<script nomodule src="assets/scripts/abortcontroller-polyfill-only.js"></script>
|
||||
|
||||
<script src="assets/scripts/vendors.js"></script>
|
||||
|
||||
Reference in New Issue
Block a user