Created
August 25, 2018 09:20
-
-
Save SevInf/c36622ecf6faec931d41507333ebdeb0 to your computer and use it in GitHub Desktop.
Live bindings demo
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export let counter = 1; | |
| export function increment() { | |
| counter++; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import { counter, increment } from './counter.mjs'; | |
| console.log(counter); // prints 1 | |
| increment(); | |
| console.log(counter); // prints 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment