Skip to content

Instantly share code, notes, and snippets.

console.log('Hello, World !');
var path = require('path');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var HtmlWebpackPluginConfig = new HtmlWebpackPlugin({
template: path.resolve(__dirname, 'src/index.html')
});
module.exports = {
entry: path.resolve(__dirname, 'src/index.js'),
output: {
body{
background: crimson;
color: white;
}
import React, { Component } from 'react';
import { render } from 'react-dom';
import './style.css';
const App = () => {
return (
<div>
<h1>Hello, World !</h1>
</div>
)
body{
background: crimson;
h1{
color: white;
}
}
import React, { Component } from 'react';
import { render } from 'react-dom';
import './style.scss';
const App = () => {
return (
<div>
<h1>Hello, World !</h1>
</div>
)
var path = require('path');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var HtmlWebpackPluginConfig = new HtmlWebpackPlugin({
template: path.resolve(__dirname, 'src/index.html')
});
module.exports = {
entry: path.resolve(__dirname, 'src/index.js'),
output: {
var path = require('path');
var HtmlWebpackPlugin = require('html-webpack-plugin');
var HtmlWebpackPluginConfig = new HtmlWebpackPlugin({
template: path.resolve(__dirname, 'src/index.html')
});
module.exports = {
entry: path.resolve(__dirname, 'src/index.js'),
output: {
import React, { Component } from 'react';
import { render } from 'react-dom';
import './style.scss';
import img from './image.jpg';
const App = () => {
return (
<div>
<h1>Hello, World !</h1>
<img src={img} alt="image" />
var gulp = require('gulp');
gulp.task('hello', function() {
console.log('Hello World !');
});