Last active
October 23, 2022 15:09
-
-
Save svierk/0983448e9ee33e3b6b24567f00a99d32 to your computer and use it in GitHub Desktop.
HTML Template for CSV Parser LWC
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<template> | |
<lightning-card title="CSV To Datatable" icon-name="doctype:csv"> | |
<div class="slds-p-around_medium"> | |
<lightning-input | |
type="file" | |
label="Please upload a UTF-8 encoded, comma separated .csv file" | |
accept=".csv" | |
onchange={handleFileUpload} | |
> | |
</lightning-input> | |
</div> | |
<div style="height: 300px"> | |
<lightning-datatable key-field="id" data={data} columns={columns} hide-checkbox-column> </lightning-datatable> | |
</div> | |
</lightning-card> | |
</template> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment