• Stars
    star
    450
  • Rank 97,143 (Top 2 %)
  • Language
    TypeScript
  • License
    Apache License 2.0
  • Created almost 6 years ago
  • Updated over 1 year ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

Data Preview 🈸 extension for importing 📤 viewing 🔎 slicing 🔪 dicing 🎲 charting 📊 & exporting 📥 large JSON array/config, YAML, Apache Arrow, Avro, Parquet & Excel data files

vscode-data-preview

Build Status Apache-2.0 License https://ko-fi.com/dataPixy

Version Installs Downloads

Data Preview 🈸 extension for importing 📤 viewing 🔎 slicing 🔪 dicing 🎲 charting 📊 & exporting 📥 large .json array .arrow .avro .parquet data files, .config .env .properties .ini .yml configurations files, .csv/.tsv & .xlsx/.xlsb Excel files and .md markdown tables with Perspective - streaming data analytics WebAssembly library.

Data Preview

🈸 Features

  • Preview .json .arrow .avro .parquet .yml .csv/.tsv & .xlsx/.xlsb data files in a Data Grid w/Sorting & Filtering
  • Grid Data Summary display w/Aggregate Functions, Row & Column Pivots (a.k.a. Group By & Split By)
  • Basic Charts 📊 creation w/Aggregate Functions, Row & Column Pivots
  • Pluggable Charting 📊 libraries for bult-in Charts: d3fc || highcharts
  • Persistent Data Preview Settings (View, Sort, Filter, Pivots, etc.) for restore of open Data View panels on VSCode Reload
  • Mulptiple Spreadsheets Data Preview for Excel data files
  • Markdown tables data preview for .md documentation files
  • Data .schema.json generation for Arrow & Avro Data Schema Text Previews in JSON format
  • Binary Data files .json generation for Arrow, Avro & Excel formats for Text Data Preview
  • Property Grid display for .json .config .env .properties .ini & .yml configuration files
  • Open Data Preview on Side option for slim data || config files
  • Quick Launch new Data Preview input box for data files in open workspace
  • Save Filtered Data Grid || Chart 📊 Data in .arrow .csv .json(s) .yml & .properties formats
  • Save & Load Data View .config options
  • Dark, Light, Dense & High Contrast Blue Data Preview 🈸 Panel UI Themes

Next V.

  • Will include large text & binary data files loading & Apache Arrow data streaming.

Note: Data Preview 🈸 is already capable of loading a few 10+MB's large data files with 100+K records & extensive list of supported Data Formats you'll be hard pressed to find on VSCode marketplace in one extension.

See data/large/... data folder for sample large data files and Data View .configs you can try in Data Preview 🈸.

Installation

Install Data Preview 🈸 via vscode Extensions tab (Ctrl+Shift+X) by searching for data preview || via VSCode marketplace search results.

List of Data Preview 🈸 extension config Settings, data.preview command(s), keyboard shortcut(s), augmented vscode UI context menus, added Data Language mappings, supported Data Files list & configurable Theme & Charts 📊 Settings:

Data Preview Contributions

Configuration

Create User or Workspace Settings in vscode to change default Data Preview 🈸 extension Settings:

Setting Type Default Value Description
data.preview.theme string dark Data Preview UI Theme: dark, light, dense.light, dense.dark, or vaporwave (hight contrast blue theme)
data.preview.charts.plugin string d3fc Data Preview Charts 📊 library to use for built-in charts: d3fc or highcharts
data.preview.create.json.files boolean false Creates .json data files for Arrow, Avro & Excel binary data formats
data.preview.create.json.schema boolean true Creates .schema.json files for Arrow & Avro metadata binary data formats
data.preview.openSavedFileEditor boolean true Opens created data file Content Editor on Data Save
data.preview.log.level string info Data Preview run log level: info or debug for issues troubleshooting

Data Preview 🈸 example using dark UI theme with d3fc Charts 📊 Data View config, viewing superstore.arrow data file :)

Data Preview Dark

Usage Tips

Data Preview 🈸 Launch Tips

  1. Run View -> Command Palette...>Data: Preview Data command or Ctrl+Shift+D in an open .json .config .env .properties .ini .yml or .csv/.tsv text data file document to launch Data Preview panel.
  2. File -> Save (Ctrl+S) your text data file for immediate updates in an open Data Preview 🈸 panel.
  3. Right-click on a Binary .xlsx/.xlsb, .arrow or .avro data file in VSCode File Explorer to launch Data Preview panel.
  4. Use exposed explorer/context, editor/title or editor/title/context Preview Data 🈸 or Preview Data on Side context menu options to preview your data files.
  5. Click on the Data View Filename toolbar link to Load saved Data View Grid || Chart 📊 .config.
  6. Click on the Data View 🈸 icon to Launch new Data Preview Panel for new view config changes.
  7. Use Open Data File or URL 📤 option from Data View toolbar to launch new Data Preview 🈸.
  8. Run View -> Command Palette...>Data: Preview Remote Data command or Ctrl+Shift+R to launch Data Preview for remote http(s) data files.

Data Preview Open Data File

Data Grid/Filter/Columns UX Tips

  1. Double click on the Grid Column header to Sort data by that column.
  2. Drag and drop a column from the left-side Columns control panel into Filter fields for data filtering (Group By, Split By, Sort, Filter).
  3. Drag columns up and down in the left-side Columns control panel to reorder displayed columns in the Data Grid.
  4. Uncheck a column in the Columns control panel to remove it from a Chart 📊 or Data Grid display.

Usage Scenarios

Use Data Preview 🈸 to:

  • Load large data files for sorting, filtering & charting 📊
  • Export displayed data in a compact binary .arrow data format, .ods .xlsb || .xlsx spreadsheet format, or .csv .json .yml .md or .properties text formats
  • Preview .properites and other key-value pairs configuration files to reformat them or find set config option values
  • Generate Arrow & Avro .shema.json for metadata text preview of those binary data files
  • Generate .json files for text data preview of binary Excel files
  • Preview Excel files and workbooks with multiple workseets without opening Excel
  • Convert .csv or .tsv data to .json or .yml format
  • Extract, sort, filter and save markdown tables from .md documentation files
  • Use built-in Charts 📊 for Exploratory Data Analysis

Supported JSON, Config, Binary & Excel Data File Formats

Tip: try sample data and Data View .config files from this repository data/... folders: data/arrow data/avro data/parquet data/config data/excel data/json data/yaml data/large

Vega datasets repository also has a broad collection of sample .csv & .json array data files you can try in Data Preview 🈸

Data Preview 🈸 Files Matching Rules

{
  "when": "resourceFilename =~ /.*\\.(json|jsonl|json5|hjson|ndjson|arrow|arr|avro|parquet|env|config|properties|ini|yml|md|csv|tsv|txt|tab|dif|ods|xls|xlsb|xlsx|xlsm|xml|html)/",
  "command": "data.preview",
  "group": "navigation"
}

Data Preview 🈸 Files Loading Details

Note: .json .config & .yml configuration files that don't contain array data are converted to flat properties key/value pairs Object and displayed in a Property Grid Data View mode. See json.utils.ts for more info.

Data File Extension(s) File Type Data Parsing Library/Method Used Data Format Specification
.json .config .jsonl .ndjson text JSON.parse() https://json.org/
.json5 text json5/JSON5.parse() https://json5.org/
.hjson text hjson-js/Hjson.parse() https://hjson.org/
.arrow .arr binary apache-arrow/Table.from() https://arrow.apache.org/
.parquet binary parquets/ParquetReader.openFile() https://parquet.apache.org/documentation/latest
.properties .env text node-properties/properties.parse() https://en.wikipedia.org/wiki/.properties
.ini text node-properties/properties.parse() https://en.wikipedia.org/wiki/INI_file
.md text RegExp/markdownToCsv() https://en.wikipedia.org/wiki/Markdown
.yml .yaml text js-yaml/yaml.load() https://yaml.org/
.csv .tsv .txt .tab text perspective/perspectiveViewer.load(text) https://en.wikipedia.org/wiki/Comma-separated_values https://en.wikipedia.org/wiki/Tab-separated_values
.dif .ods .xls .xlsb .xlsx .xlsm .xml .html binary/text js-xlsx/XLSX.read() See https://github.com/SheetJS/js-xlsx#file-formats for more info on Excel file formats

See Data Manager API & src/data.providers folder for data loading and saving imlementation details.

Provided Chart 📊 Types

  • Area Chart
  • Bar Chart
  • Candlesick Chart (d3fc only))
  • Heatmap
  • Line Chart
  • OHLC Chart (d3fc only)
  • Scatter Chart
  • Sunburst
  • Tree Map

Data Preview Chart Types

Supported Filter Functions

  • <, <=, ==, !=, >, >= for dates and number columns/fields
  • ==, !=, contains, in, not in, begins with, ends with for string fields and dictionaries
  • &, |, and, or, ==, != for bolean fields

Supported Aggregate Functions

  • any
  • avg
  • count
  • distinct count
  • dominant
  • first by index
  • last by index
  • last
  • high
  • low
  • mean
  • mean by count
  • median
  • pct sum parent
  • pct sum grand total
  • sum
  • sum abs
  • sum not null
  • unique

Recommended VSCode Extensions

Other extensions Data Preview 🈸 replaces, enhances or supplements for working with supported data file formats in VSCode:

Extension Description
Excel Viewer View Excel spreadsheets and CSV files
Avro Viewer .avro file viewer
avro-idl Avro IDL Syntax Highlighter
DotENV .env Syntax Highlighter
Ini for VSCode Provides outline view and section folding for INI files
Hjson Hjson language syntax support
JSON5 syntax Adds syntax highlighting of JSON5 files
NDJSON Colorizer Colorizes NDJSON (Newline Delimited JSON) files
YAML YAML Language Support by Red Hat, with built-in Kubernetes and Kedge syntax support
docs-yaml YAML schema validation and auto-completion for docs.microsoft.com authoring
YAML to JSON Convert YAML from clipboard or current document/selection to JSON and vice versa
Properties To Yaml Convert properties to yaml
Markdown Table Prettifier Transforms markdown tables to be more readable

Dev Log

See #DataPreview 🈸 tag on Twitter for the latest and greatest updates on this vscode extension and what's in store next.

Dev Build

$ git clone https://github.com/RandomFractals/vscode-data-preview
$ cd vscode-data-preview
$ npm install
$ code .

F5 to launch Data Preview extension VSCode debug session.

||

vscode-data-preview>vsce package

to generate VSIX Data Preview extension package from our latest for local dev install in VSCode.

Note: Use Help -> Toggle Developer Tools vscode menu option to view Data Preview console log.

Contributions

Any and all test, code or feedback contributions are welcome.

Open an issue or create a pull request to make this Data Preview 🈸 extension work better for all.

Backers

SheetJS Aman Mittal
support me on ko-fi.com

More Repositories

1

geo-data-viewer

Geo Data Analytics tool for VSCode IDE with kepler.gl support to generate and view maps 🗺️ without any Python 🐍, IPyWidgets ⚙️, pandas 🐼, Jupyter notebooks 📚, or ReactJS ⚛️ app code.
HTML
320
star
2

vscode-vega-viewer

VSCode extension for Interactive Preview of Vega and Vega-Lite maps 🗺️ and graphs 📈.
TypeScript
112
star
3

chicago-crimes

Exploring Chicago crimes dataset with Jupyter notebooks, DuckDB, Malloy and new Panel/PyScript data and dashboard tools.
Jupyter Notebook
33
star
4

js-notebook-inspector

JS Notebook 📓 Inspector 🕵️ -> vscode extension for Interactive Preview of Observable JS Notebooks 📚 & Notebook 📓 Nodes ⎇ & Cells ⌗ source code.
JavaScript
24
star
5

vscode-data-table

Data Table 🈸 , Flat Data Grid 中 & Data Summary 🈷️ Renderers for VSCode Notebook 📓 Cell ⌗ Data Outputs
JavaScript
24
star
6

observable-data-tools

Repository of web and code editor friendly Observable Data Toools 🛠️ and Notebooks 📚 in .js, .nb.json, .ojs, .omd, .html and .qmd document formats for Data Previews in a browser and in VSCode IDE with Observable JS extension, Quarto extension, and new Quarto publishing tools.
JavaScript
22
star
7

unfolded-maps

Unfolded Studio sample maps 🗺️ with Observable JS 📓, Jupyter/.Net Interactive notebooks 📚 & Unfolded Map SDK
JavaScript
20
star
8

duckdb-sql-tools

DuckDB SQL Tools add DuckDB support to VSCode, and provide database schema and SQL query interfaces for the popular SQLTools extension, SQL query editor, language server, and data processing tools.
Jupyter Notebook
20
star
9

ChicagoCrimes

Exploring public Chicago crimes data set in Python
Jupyter Notebook
18
star
10

CensusD3

interactive d3.js v.4 maps and graphs data viz of US census data from census.gov
Vue
14
star
11

tabular-data-viewer

Tabular Data Viewer 🀄 VSCode extension for viewing very large local and remote CSV and TSV data files with Tabulator Table, Perspective Datagrid and D3FC Chart Views 📊📈
TypeScript
12
star
12

vscode-marketplace-ext-stats

VSCode Marketplace Extension Stats tool to get periodic Installs & Downloads counts for Visual Studio family of products extension authors
JavaScript
10
star
13

CyberDash

code behind @WebDevCreations @WebPackSense and @CyberDash Twitter bots
JavaScript
9
star
14

venn-diagram-generator

we do it for #dataSci tech lulz :)
TypeScript
8
star
15

Chicago-transportation-notebooks

Demo notebooks 📚 using public city of Chicago Transportation datasets.
JavaScript
8
star
16

americans

Bots demo project of USA census population data
JavaScript
5
star
17

droneStrikes

Data viz of US drone strikes in the Middle East
CSS
5
star
18

paradise-campfire-map

omniSci visualization of Paradise, California 2018 campfire
JavaScript
5
star
19

Ukraine-geo-data

Data repository for geo spatial applications about Ukraine.
4
star
20

unfolded-map-snippets

Html, CSS, JavaScript, and Python 🐍 vscode snippets ✂️ extension for Unfolded Map 🗺️ and Data SDKs
Jupyter Notebook
4
star
21

unfolded-map-react

unfolded map 🗺️ react app
JavaScript
4
star
22

vscode-snippets-viewer

Snippets viewer for VSCode
TypeScript
4
star
23

AdventureWorks

Asp.Net MVC 5/Dapper AdventureWorks Sales Orders Sample App
JavaScript
3
star
24

vscode-extension-snippets

VScode Snippets extension for creating vscode extensions ;)
2
star
25

data-laboratory

vscode data laboratory extensions pack
2
star
26

js-notepad

js-notepad
2
star
27

unfolded-map-renderer

Unfolded Map 🗺️ Notebook 📓 Renderer for VSCode.
TypeScript
2
star
28

jupyterlite-demo

JupyterLite Demo
Jupyter Notebook
1
star
29

data-core

Common data core repository for data extensions
1
star
30

vscode-agent-cody

new super secret vscode ext. proj. ;) 🕵️‍♀️
1
star
31

vscode-js-notebooks

VSCode JavaScript Notebooks
HTML
1
star
32

vscode-charts

Generic charts vscode extension ...
1
star
33

world-migrations

World Migrations Data Viz
Vue
1
star
34

observable-cors

Glitch cors proxy for https://beta.observablehq.com
JavaScript
1
star
35

ISpyAI

testbed for I Spy books OCR and image recognition AI
Jupyter Notebook
1
star
36

keplergl-notebook-renderer

Kepler.gl Jupyter notebook flat geo data output renderer for VSCode IDE.
TypeScript
1
star
37

chicago-transport

Exploratory data analysis of public Chicago transportation datasets.
Jupyter Notebook
1
star
38

random-bits

random python/js bits
Jupyter Notebook
1
star
39

vscode-svelte-repl

vscode-svelte-repl
1
star
40

vega-unfurl

Slack app for Vega Editor links preview
JavaScript
1
star