Skip to content

Instantly share code, notes, and snippets.

Paul dagda1

Block or report user

Report or block dagda1

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
function rstvsc()
killall Electron 2> /dev/null
code .
function rstvsc_log()
rm ~/.tslog 2> /dev/null
TSS_LOG="-level verbose -file /Users/paulcowan/.tslog" rstvsc
threads = 1,
runLevel = CourgetteRunLevel.FEATURE,
rerunFailedScenarios = true,
showTestOutput = true,
public class TestRunner {
View foo.ts
interface Foo {
value?: string;
const item1: Foo = { value: 'foo' }
// ERROR: Object is possibly 'undefined'.
console.log(`Message ${item1.value.substring(4)}`);
const item2 = { value: 'foo' }
View analyse.js
process.env.NODE_ENV = 'production';
const webpack = require('webpack');
const BundleAnalyzerPlugin = require('webpack-bundle-analyzer').BundleAnalyzerPlugin;
const webpackConfigProd = require('react-scripts/config/webpack.config')('production');
// this one is optional, just for better feedback on build
const chalk = require('chalk');
const ProgressBarPlugin = require('progress-bar-webpack-plugin');
const green = text => {
View tsconfig.json
"exclude": [
View Heagaon.ts
export enum HexagonType {
flat = 'flat',
pointy = 'pointy'
View tailwind.css
<button class="bg-blue hover:bg-blue-dark text-white font-bold py-2 px-4 rounded">
View gist:94a91f0fbb7a86f541be142543bc0255
$spacing: 0.625; // 4px
$unit: rem;
$spacing-x1: #{$spacing}#{$unit} !important;
$spacing-x2: #{$spacing * 2}#{$unit} !important;
$spacing-x3: #{$spacing * 3}#{$unit} !important;
$spacing-x4: #{$spacing * 4}#{$unit} !important;
$spacing-x5: #{$spacing * 5}#{$unit} !important;
$spacing-x6: #{$spacing * 6}#{$unit} !important;
$spacing-x7: #{$spacing * 7}#{$unit} !important;
View splitchunks.js
cacheGroups: {
styles: {
name: 'styles',
test: /\.s?css$/,
chunks: 'all',
minChunks: 1,
reuseExistingChunk: true,
enforce: true,
View text.ts
import React, { useState, useEffect, useRef } from 'react';
import { LabelProps, LabelPosition } from '../../types';
import cs from 'classnames';
import { Text } from '@vx/text';
const styles = require('./LabelCompressed.scss');
export interface LabelPositioningProps {
angle: number;
You can’t perform that action at this time.