Usage
How to use in Data.js
Usage
This framework syntax very simple
const Data = require("./data"); // importing data.js
var app = new Data(["data.js","javascript",14,25,9,16], // the main array that the framework takes
{
get: 0, // returns the desired value from the array
getLength: true, // returns length of array
join: ", ", // places the desired value between array values
copy: 1, // copies any value in the array
constructor: true, // returns the data type
entries: true, // returns the data type
reverse: true, // displays the values in reverse order.
sort: true, // sorts the values in alphabetical order
fill: "data.js", // replaces the array values with the value in this method
shift: true, // assigns the first value
map: Math.sqrt, // delete array values
pop: true // returns the final value
});
Last updated