This file contains 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 path = require('path'); | |
const HtmlWebpackPlugin = require('html-webpack-plugin'); | |
module.exports = { | |
entry: './src/app.js', | |
target: 'web', | |
node: { | |
fs: 'empty' | |
}, | |
output: { |
This file contains 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
WebpackOptionsValidationError: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema. | |
- configuration has an unknown property 'default'. These properties are valid: | |
object { mode?, amd?, bail?, cache?, context?, dependencies?, devServer?, devtool?, entry?, externals?, loader?, module?, name?, node?, output?, optimization?, parallelism?, performance?, plugins?, profile?, recordsInputPath?, recordsOutputPath?, recordsPath?, resolve?, resolveLoader?, serve?, stats?, target?, watch?, watchOptions? } | |
For typos: please correct them. | |
For loader options: webpack >= v2.0.0 no longer allows custom properties in configuration. | |
Loaders should be updated to allow passing options via loader options in module.rules. | |
Until loaders are updated one can use the LoaderOptionsPlugin to pass these options to the loader: | |
plugins: [ | |
new webpack.LoaderOptionsPlugin({ | |
// test: /\.xxx$/, // may apply this only for some modules |
This file contains 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 path = require('path'); | |
module.exports = { | |
entry: './src/app.js', | |
target: 'web', | |
node: { | |
fs: 'empty' | |
}, | |
output: { | |
path: path.join(__dirname, 'public'), |
This file contains 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 React from 'react'; | |
export default class Action extends React.Component { | |
constructor(props) { | |
super(props); | |
this.state = { | |
val: '' | |
} |
This file contains 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 React from 'react'; | |
export default class Action extends React.Component { | |
constructor(props) { | |
super(props); | |
this.handleAction = this.handleAction.bind(this); | |
} | |
handleAction (e) { |
This file contains 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
{ | |
"name": "tests", | |
"version": "1.0.0", | |
"description": "", | |
"main": "index.js", | |
"scripts": { | |
"test": "mocha **/*.test.js", | |
"test-watch": "nodemon --exec \"npm test\"" | |
}, | |
"author": "", |
This file contains 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
[ | |
{ | |
"key": "\\frac{num}{den}", | |
"description": "Create a fraction. The num stands for numerator and den for denominator" | |
}, | |
{ | |
"key": "\\dfrac{num}{den}", | |
"description": "Fraction in display mode" | |
}, | |
{ |
This file contains 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
[ | |
{ | |
"key": " ", | |
"desc": " \n" | |
}, | |
{ | |
"key": "\\* ", | |
"desc": "erminates a line, but disallows a pagebreak.\n" | |
}, | |
{ |
This file contains 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
[ | |
{ | |
"key": "", | |
"desc": " \\\\* terminates a line, but disallows a pagebreak.\n" | |
}, | |
{ | |
"key": "", | |
"desc": "\n" | |
}, | |
{ |
This file contains 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
[ | |
{ | |
"keyword": "factorial", | |
"syntax": "\\frac{numerator}{denominator}" | |
}, | |
{ | |
"keyword": "binomial", | |
"syntax": "\\binom{n}{k}" | |
}, | |
{ |