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
| var currencyValidator = { | |
| format: function (number) { | |
| return (Math.trunc(number * 100) / 100).toFixed(2) | |
| }, | |
| parse: function (newString, oldNumber) { | |
| var CleanParse = function (value) { | |
| return { value: value } | |
| } | |
| var CurrencyWarning = function (warning, value) { | |
| return { |
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
| const person = { | |
| firstName: 'Douglas', | |
| lastName: 'Adams' | |
| }; | |
| function outputName(user) { | |
| return `${user.firstName} ${user.lastName}`; | |
| } | |
| const App = ( |
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
| npm init | |
| npm install --save react react-dom |
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
| npm install -g create-react-app | |
| create-react-app hello-world | |
| cd hello-world | |
| npm start |
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
| <script src="https://unpkg.com/react@15/dist/react.js"></script> | |
| <script src="https://unpkg.com/react-dom@15/dist/react-dom.js"></script> |
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
| <template> | |
| <transition | |
| name="fade" | |
| mode="out-in" | |
| v-on:before-enter="beforeEnter" | |
| v-on:enter="enter" | |
| v-on:before-leave="beforeLeave" | |
| v-on:leave="leave" | |
| > | |
| <slot></slot> |