Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
<html lang="en">
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>JS Module in Browser</title>
<script type="module" src="./js/main.js"></script>
import { fullname } from './person.mjs';
document.body.innerHTML += `<h1>${ fullname('Junio', 'Vitorino') }</h1>`
export const fullname = (firstname, lastname) => `${firstname} ${lastname}`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.