materialize-tabs

Standalone materialize-css tabs

Usage no npm install needed!

<script type="module">
  import materializeTabs from 'https://cdn.skypack.dev/materialize-tabs';
</script>

README

materialize-tabs

materialize-tabs is standalone the tabs component taken from materialize-css. It's dependent only on jQuery.

Install

$ npm install materialize-tabs

Usage

Use with browserify as,

require('materialize-tabs');
// This will attach tabs to jQuery
// You do not need to declare jQuery as a global

For direct use in a browser,

<link rel="stylesheet" type="text/css" href="/dist/jquery.materialize-tabs.min.css">
<script type="text/javascript" src="/dist/jquery.materialize-tabs.min.js"></script>

This includes jQuery as well.

If jQuery is already present, use,

<link rel="stylesheet" type="text/css" href="/dist/jquery.materialize-tabs.css">
<script type="text/javascript" src="/src/js/tabs.js"></script>

Make sure you include jQuery before including tabs.js

For calling the api, refer http://materializecss.com/tabs.html