js export multiple functions

JavaScript
//Inside lib file declare functions
const animalName = (name) => {
	console.log(name)
}
const animalSound = (sound) => {
	console.log(sound)
}
//Export these both as JSON
module.exports = {animalName, animalSound}

//Navigate to file you want to use them and import
const animalLib = require('./location_of_file.js')

//To access the function
animalLib.animalName("zebra")function foo() { console.log('foo') }
function bar() { console.log('bar') }
function baz() { foo(); bar() }

export default {foo, bar, baz}
Source

Also in JavaScript: