This file contains 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
const [myDate, setMyDate] = useState() | |
const pad2 = (num: number): string => num < 10 ? '0' + num : num.toString(); | |
const utcAsLocalString = (date: Date | undefined): string | undefined => { | |
if (date == null) return undefined; | |
return (date.getFullYear() + '-' + pad2(date.getMonth()) + '-' + date.getDate() + 'T' + pad2(date.getHours()) + ':' + pad2(date.getMinutes()) + ':' + pad2(date.getSeconds())) | |
} | |
<input |
This file contains 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
Show hidden characters
{ | |
"ignored_packages": | |
[ | |
"Vintage", | |
], | |
"theme": "ayu-mirage.sublime-theme", | |
"margin": 2, | |
"tab_size": 2, | |
"translate_tabs_to_spaces": true, | |
"color_scheme": "Packages/ayu/ayu-mirage.sublime-color-scheme", |
This file contains 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
const TableWrapper = ({ | |
title, | |
isHidden, | |
data | |
}: { title, isHidden, data }) => { | |
if (!data || data.length <= 0) return | |
const headers = Object.keys(data[0]).filter(key => !isHidden.includes(key)) | |
return ( | |
<> | |
<h3>{title}</h3> |
This file contains 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
import React, { useState } from 'react'; | |
interface Props { | |
activeTab: String, | |
children: any | |
} | |
interface TabProps { | |
title: String; | |
label: String; |
This file contains 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
default partial alphanumeric_keys modifier_keys | |
xkb_symbols "pc105" { | |
key <ESC> { [ Escape ] }; | |
// The extra key on many European keyboards: | |
key <LSGT> { [ less, greater, bar, brokenbar ] }; | |
// The following keys are common to all layouts. | |
key <BKSL> { [ backslash, bar ] }; |
This file contains 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
# Theme | |
ZSH_THEME="robbyrussell" | |
# PATH exports | |
PATH=$PATH:/usr/local/bin/; export PATH | |
export PATH=/usr/local/share/npm/bin:$PATH | |
export ZSH="/Users/xamkcm/.oh-my-zsh" | |
# Alias's for git | |
alias gs='git status' |
This file contains 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
import { storiesOf } from '@storybook/react'; | |
import React from 'react'; | |
storiesOf('example', module) | |
.add( | |
'example', | |
() => ( | |
<div> | |
<div></div> | |
</div> |
This file contains 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
const path = require('path'); | |
// your app's webpack.config.js | |
const custom = require('../build/webpack.base.js'); | |
module.exports = async ({ config, mode }) => { | |
return { ...config, | |
module: { | |
...config.module, | |
rules: custom.module.rules, | |
}, |
This file contains 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
:root { | |
font-size: 16px; | |
} | |
@function pow($number, $exponent) { | |
$value: 1; | |
@if $exponent > 0 { | |
@for $i from 1 through $exponent { | |
$value: $value * $number; |
This file contains 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
import React from 'react'; | |
import classes from './Table.module.css'; | |
const Row = props => { | |
return props.keys.map((key) => { | |
return <td key={props.data[key]}>{props.data[key]}</td> | |
}) | |
} | |
const Table = ({ |
NewerOlder