Hi Vivek,
You can save an array with local storage, and also with the chrome.storage API. See this code example on this developer page:
You can implement your Chrome extension using the following JavaScript code:
const defaultSettings = {
general: {
},
textColors: {
},
sideNavbar: {
},
navbar: {
},
searchbox: {
},
chips: {
}
};
// Load the settings from storage, or use the default settings if none exist
chrome.storage.local.get('settings', (result) => {
const settings = result.settings || defaultSettings;
// Use the settings to configure your extension
// ...
// Save any changes to the settings
chrome.storage.local.set({ settings });
});
A tip: If you use chrome.storage.sync.set, the settings will be synced to all of the user's Chrome web browsers.
Thanks,