Fix spacing in code sample.
This commit is contained in:
parent
7f0ac04db5
commit
2159c8792b
|
@ -227,14 +227,15 @@ class MyThing {
|
||||||
gl.MyThing = new MyThing();
|
gl.MyThing = new MyThing();
|
||||||
|
|
||||||
// best
|
// best
|
||||||
|
|
||||||
let singleton;
|
let singleton;
|
||||||
|
|
||||||
class MyThing {
|
class MyThing {
|
||||||
constructor() {
|
constructor() {
|
||||||
if (!singleton) {
|
if (!singleton) {
|
||||||
singleton = this;
|
singleton = this;
|
||||||
singleton.init();
|
singleton.init();
|
||||||
}
|
}
|
||||||
return singleton;
|
return singleton;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -246,6 +247,7 @@ class MyThing {
|
||||||
}
|
}
|
||||||
|
|
||||||
gl.MyThing = MyThing;
|
gl.MyThing = MyThing;
|
||||||
|
|
||||||
```
|
```
|
||||||
|
|
||||||
## Supported browsers
|
## Supported browsers
|
||||||
|
|
Loading…
Reference in New Issue