1.1.0 • Published 3 years ago
tbjsl v1.1.0
TBJSL A lightweight JS library
Install
npm i tbjsl
Getting Started
Add the tbjsl.js From The dist directory in the node_modules for this package into your public directory
<script src="/dist/tbjsl.js"></script>
Tests
$tb('#test').html(); //get an element with an id of test and return the html
$tb('#test').html('<p>html changed</p>'); //set the html of an element with an id of test
$tb('#test').text(); //get an element with an id of test and return the text
$tb('#test').text('text changed'); //set the text of an element with an id of test
$tb('#test').val(); //get the value of an input field with an id of test
$tb('#test').val('12345'); //set the value of an input field with an id of test
$tb('#test').addClass('test'); //add a class of test to element with an id of test
$tb('#test').hasClass('test'); //check if an id of test has class of test
$tb('#test').removeClass('test'); //remove a class of test from an element with an id of test
Updates
I will be updating the package weekly more functions will be added