Last active
October 16, 2020 08:39
-
-
Save 3dln/c16d33ed898aa9e039f6257f06a24bc6 to your computer and use it in GitHub Desktop.
virgool webpack tutorial
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 _ from 'lodash'; | |
import './style.css'; | |
import Logo from './icon.png'; | |
function component() { | |
const element = document.createElement('div'); | |
element.innerHTML = _.join(['Hello', 'webpack'], ' '); | |
element.classList.add('hello'); | |
const logo = new Image(); | |
logo.src = Logo; | |
element.appendChild(logo); | |
return element; | |
} | |
document.body.appendChild(component()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment