
Research
Security News
The Growing Risk of Malicious Browser Extensions
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
simple-csv-editor
Advanced tools
A table editor for easily editing and retrieving CSV data.
Demo page - can be found under demo/index.html
npm install --save simple-csv-editor
Here is a basic HTML setup which should cover most needs:
<!-- The element in which the table editor will be displayed -->
<div id="simpleCsvEditor"></div>
<!-- PapaParse CSV parser dependency - very important for the editor to work!
Of course you can also use the library via "npm i papaparse" or download it yourself.
At least the vendored version here guarantees compatibility with the editor. -->
<script src="papaparse.min.js"></script>
<!-- ES module declaration -->
<script type="module">
import SimpleCsvEditor from './simple-csv-editor.js';
// Initializes the editor with config parameters:
// id: Set according to the editor HTML element's id attribute
// onChange: This function will be executed everytime a change happens inside the editor.
// The paramater will contain the current CSV representation of the editor.
// delimiter: If not set it will be auto-detected, you might want to supply the delimiter to get consistent behavior.
const simpleCsvEditor = new SimpleCsvEditor({
id: 'simpleCsvEditor',
data: '1,2,3', // init with data already
onChange: (csvData) => { console.log(csvData); },
delimiter: ',',
});
// Set the CSV data. maybe check out the demo, you might want to set this using a text area or some other way.
// Returns an array of CSV parsing errors - should be empty if everything is fine
const errors = simpleCsvEditor.setCsv(`1,2,3,4
one,two,three,four`);
// Fetch the data again from the table
const csvData = simpleCsvEditor.getCsv();
</script>
For all public methods, properties and further constructor config parameters check out src/simple-csv-editor.js
- it should be very readable 😜
FAQs
A table editor for easily editing and retrieving CSV data.
The npm package simple-csv-editor receives a total of 2 weekly downloads. As such, simple-csv-editor popularity was classified as not popular.
We found that simple-csv-editor demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket researchers uncover how browser extensions in trusted stores are used to hijack sessions, redirect traffic, and manipulate user behavior.
Research
Security News
An in-depth analysis of credential stealers, crypto drainers, cryptojackers, and clipboard hijackers abusing open source package registries to compromise Web3 development environments.
Security News
pnpm 10.12.1 introduces a global virtual store for faster installs and new options for managing dependencies with version catalogs.