Immutable.js has one more tool for creating immutable data in addition to everything we've looked at so far in this chapter. The fromJS() function is similar to a JSON parser, because it parses the same types of JavaScript objects that you'll see when you parse JSON strings: objects and arrays.
Parsing data using the fromJS() function
Parsing JavaScript arrays
You can parse a regular JavaScript array, resulting in a list, as shown here:
import { fromJS } from 'immutable';
const myList = fromJS([1, 2, 3]);
console.log('myList', myList.get(0));
// -> myList 1
This is just like passing the array to the List constructor.