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
// 3D Dom viewer, copy-paste this into your console to visualise the DOM as a stack of solid blocks. | |
// You can also minify and save it as a bookmarklet (https://www.freecodecamp.org/news/what-are-bookmarklets/) | |
(() => { | |
const SHOW_SIDES = false; // color sides of DOM nodes? | |
const COLOR_SURFACE = true; // color tops of DOM nodes? | |
const COLOR_RANDOM = false; // randomise color? | |
const COLOR_HUE = 190; // hue in HSL (https://hslpicker.com) | |
const MAX_ROTATION = 180; // set to 360 to rotate all the way round | |
const THICKNESS = 20; // thickness of layers | |
const DISTANCE = 10000; // ¯\\_(ツ)_/¯ |
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 fs from 'fs'; | |
import path from 'path'; | |
import { defineConfig } from 'tsup'; | |
// INFO: This is the only place you need to update when adding new entry folders | |
const entryFolders = ['primitives', 'ui']; | |
function getAllFilesInDirectory(dirPath: string): string[] { | |
return fs.readdirSync(dirPath).reduce<string[]>((allFiles, file) => { |
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 ordinalizeNumber = n => { | |
const rule = new Intl.PluralRules('en-US', { type: 'ordinal' }).select(n); | |
const suffix = ({ | |
one: 'st', | |
two: 'nd', | |
few: 'rd', | |
other: 'th', | |
})[rule]; | |
return `${n}${suffix}`; | |
} |
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
// This file is used to override the REST API resources configuration | |
import { AmplifyApiRestResourceStackTemplate } from "@aws-amplify/cli-extensibility-helper"; | |
export function override(resources: AmplifyApiRestResourceStackTemplate) { | |
// Add our user pool id as a parameter so we can create authorizers with it | |
// Note that you have to replace <your auth name here> with the name of your auth! | |
// It's the name of the folder in amplify/backend/auth that was created when you | |
// added the auth to the project (NOT userPoolGroups). Also make sure you keep | |
// the preceding "auth" part of the string before the auth name, it's necessary. | |
resources.addCfnParameter( |
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
This is an example with a simple TODO schema: | |
```graphql | |
type Todo @model { | |
id: ID! | |
name: String! | |
description: String | |
} | |
``` |
This is a guide for aligning images.
See the full Advanced Markdown doc for more tips and tricks
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
/* http://meyerweb.com/eric/tools/css/reset/ | |
v2.0-modified | 20110126 | |
License: none (public domain) | |
*/ | |
html, body, div, span, applet, object, iframe, | |
h1, h2, h3, h4, h5, h6, p, blockquote, pre, | |
a, abbr, acronym, address, big, cite, code, | |
del, dfn, em, img, ins, kbd, q, s, samp, | |
small, strike, strong, sub, sup, tt, var, |
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
The licenses in the npm-registry from their package.json, from the latest version of each module | |
23.11.2013 | |
[ { key: 'undefined', value: 27785 }, | |
{ key: 'MIT', value: 20811 }, | |
{ key: 'BSD', value: 5240 }, | |
{ key: 'BSD-2-Clause', value: 621 }, | |
{ key: 'Apache 2.0', value: 263 }, | |
{ key: 'GPL', value: 233 }, |
NewerOlder