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 {Action, ActionCreator, Dispatch} from 'redux'; | |
| import {ThunkAction} from 'redux-thunk'; | |
| // Redux action | |
| const reduxAction: ActionCreator<Action> = (text: string) => { | |
| return { | |
| type: SET_TEXT, | |
| text | |
| }; | |
| }; |
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
| // Show rendered HTML | |
| const wrapper = shallow(<App />) | |
| console.log(wrapper.debug()) | |
| // Disable lifecycle methods of react within tests | |
| const wrapper = mount(<App />, { disableLifecycleMethods: true }) | |
| // Assert number of occurrences | |
| expect(wrapper.find('p').length).toBe(1) |
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
| https://github.com/eligrey/FileSaver.js/ |
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
| https://stackoverflow.com/a/49190517/217372 |
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
| Link: https://sindresorhus.com/multi-download/browser.js |
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
| https://stackoverflow.com/a/38914917 |
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
| Link: https://stackoverflow.com/questions/44594532/how-to-add-ng-model-functionality-to-a-component/44595910#44595910 | |
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
| # config is located here: /etc/nginx/sites-available | |
| # Default server configuration | |
| # | |
| server { | |
| listen 80 default_server; | |
| listen [::]:80 default_server; | |
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
| How to change ExecJS runtime in RoR |
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
| You can use isState filter with either ng-show or ng-hide. | |
NewerOlder