Added temp src js files
This commit is contained in:
parent
2e6436fb12
commit
2e1dfd387a
12
src/card.js
Normal file
12
src/card.js
Normal file
@ -0,0 +1,12 @@
|
||||
export default class Card {
|
||||
constructor() {
|
||||
this._num = 0;
|
||||
this._color = 'red';
|
||||
}
|
||||
get num() {
|
||||
return this._num;
|
||||
}
|
||||
set num(num) {
|
||||
this._num = num;
|
||||
}
|
||||
}
|
||||
6
src/index.js
Normal file
6
src/index.js
Normal file
@ -0,0 +1,6 @@
|
||||
console.log('asd')
|
||||
//const Card = require(['js/card.js']);
|
||||
import Card from './card.js';
|
||||
console.log('asdzxc')
|
||||
let card = new Card();
|
||||
console.log(card.num)
|
||||
Loading…
x
Reference in New Issue
Block a user