I would simply like to use the functions from Lodash on my website.
I included this in the <head>
section:
<script scr="https://cdn.jsdelivr.net/npm/[email protected]/lodash.min.js"></script>
What else should I do? I tried to add:
<script>
var _ = require('lodash');
</script>
But I get the following error:
Uncaught ReferenceError: require is not defined
require
. You use_
directly. Since you've incuded thejs
file, you can use it like you do with jquery.