Skip to content

Instantly share code, notes, and snippets.

@eggei
eggei / datap-types.ts
Last active August 2, 2020 17:05
Data Visualization Libraries Comparison - Data Types
// https://codesandbox.io/s/white-snow-1u6ei
// D3 in React Chart Data
type D3Data = Array<{
date: string,
point1: number,
point2: number,
}>
// Victory Chart Data
@eggei
eggei / recharts-simple-line-data.ts
Last active January 6, 2022 03:18
recharts-simple-line
type data = Array<{
name: string
uv: number
pv: number
amt: number
}>
@eggei
eggei / victory-simple-line-data.ts
Last active August 5, 2020 02:24
victory-simple-line
type data = Array<{
x: number
y: number
}>
@eggei
eggei / nivo-simple-line-data.ts
Created August 5, 2020 02:41
nivo-simple-line
type data = Array<{
id: string
data: Array<{
x: string
y: string
}>
}>
@eggei
eggei / react-vis-simple-line-data.ts
Last active August 27, 2020 18:51
react-vis-simple-line
type data = Array<{
x: number
y: number
}>
@eggei
eggei / viser-simple-line-data.ts
Last active August 27, 2020 20:20
viser-simple-line
type data = Array<{
year: string
value: number
}>
@eggei
eggei / d3-in-react.jsx
Last active August 5, 2020 03:54
d3-in-react
const config = {
width: xStyles.width,
height: xStyles.height,
margin: {
top: 40,
right: 40,
bottom: 40,
left: 40
},
color: {
@eggei
eggei / modal-abstraction.tsx
Last active January 15, 2021 20:14
Abstraction or no abstraction?
/* MUI interface for modals */
<Dialog
open={openSaveDialog}
onClose={toggle}
aria-labelledby="form-dialog-title"
maxWidth="sm"
fullWidth
>
<DialogTitle>{title}</DialogTitle>
@eggei
eggei / ege-ide
Created September 27, 2023 12:56
{"name":"ege-ide","settings":"{\"settings\":\"{\\n \\\"window.titleBarStyle\\\": \\\"custom\\\",\\n \\\"editor.multiCursorModifier\\\": \\\"ctrlCmd\\\",\\n \\\"editor.codeActionsOnSave\\\": {\\n \\\"source.fixAll.eslint\\\": true\\n },\\n \\\"editor.formatOnSave\\\": true,\\n \\\"[javascript]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"rvest.vs-code-prettier-eslint\\\"\\n },\\n \\\"[json]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"[jsonc]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"[typescriptreact]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\\n },\\n \\\"[javascriptreact]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"rvest.vs-code-prettier-eslint\\\"\\n },\\n \\\"[typescript]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"rvest.vs-code-prettier-eslint\\\"\\n },\\n \\\"[html]\\\": {\\n \\\"editor.defaultFormatter\\\": \\\"esbenp.prettier-vscode\\\"\
@eggei
eggei / application.rb
Last active April 19, 2024 13:56
This gist lists the codes needed for the LTI deep linking testing configuration in [Kyron LTI - INTERNAL(for Devs)](https://docs.google.com/document/d/1h5APlAp_Vtz1DMZjY9MwzceU0MRV5tW5oAgxHsT2W1I/edit#heading=h.2k118he6h471) documentation under `Testing > Testing in Canvas section`
# Copy paste this in the application.rb file to allow connections from ngrok proxy
# (You might wanna change the host below according to the URL NGROK command yields)
config.hosts << '.ngrok-free.app'