Skip to content

Instantly share code, notes, and snippets.

View Robbie-Cook's full-sized avatar
🎯

Robbie Cook Robbie-Cook

🎯
View GitHub Profile
''
'' sketchy-outline theme based off of the bootstrap theme of the same name
'' https://bootswatch.com/sketchy/
''
'' Author = "Brett Schwarz
'' Copyright (c) 2020 by Brett Schwarz
!$THEME = "sketchy-outline"
!if %not(%variable_exists("$BGCOLOR"))
@Robbie-Cook
Robbie-Cook / tsconfig.json
Created November 13, 2020 07:55
A tsconfig.json for webpack and normal projects.
{
"compilerOptions": {
/* Visit https://aka.ms/tsconfig.json to read more about this file */
/* Basic Options */
// "incremental": true, /* Enable incremental compilation */
"target": "es5" /* Specify ECMAScript target version: 'ES3' (default), 'ES5', 'ES2015', 'ES2016', 'ES2017', 'ES2018', 'ES2019', 'ES2020', or 'ESNEXT'. */,
"module": "commonjs" /* Specify module code generation: 'none', 'commonjs', 'amd', 'system', 'umd', 'es2015', 'es2020', or 'ESNext'. */,
// "lib": [], /* Specify library files to be included in the compilation. */
"allowJs": true /* Allow javascript files to be compiled. */,
const path = require("path");
module.exports = {
entry: path.resolve(__dirname, "./src/index.ts"),
output: {
path: path.resolve(__dirname, "./umd"),
filename: "index.js",
libraryTarget: "umd",
library: "MyPackageName",
},
@Robbie-Cook
Robbie-Cook / webpack.config.js
Last active January 11, 2021 10:31
A Webpack config for compiling libraries (including React component libraries)
const nodeExternals = require("webpack-node-externals");
const path = require("path");
module.exports = {
entry: path.resolve(__dirname, "./src/index.ts"),
output: {
path: path.resolve(__dirname, "./dist"),
filename: "index.js",
libraryTarget: "commonjs2"
},
@Robbie-Cook
Robbie-Cook / README.md
Created September 30, 2020 01:29
Introduction

Hello!

Welcome to my profile!

I maintain the following open-source packages. I am really keen to take contributions, or questions. Email me at [email protected]!

Node helper functions. Especially good for fetch requests with bearer tokens and questioning the user.

@Robbie-Cook
Robbie-Cook / README.md
Last active April 5, 2024 01:34
React Library Webpack Configuration
{
"component": {
"prefix": ["svelte-component"],
"body": [
"<script lang=\"typescript\">",
"",
"</script>",
"",
"<style lang=\"scss\">",
" .c-${1:Component} {",
{
"component": {
"prefix": ["svelte-component"],
"body": [
"<script lang="typescript">",
"",
"</script>",
"",
"<style lang="scss">",
" .c-${1:Component} {",
aws lambda update-function-code --function-name my-function --zip-file fileb://./my-code.zip
@Robbie-Cook
Robbie-Cook / react-component.code-snippets
Last active August 16, 2020 04:56
React Component Snippet
{
"component": {
"scope": "typescriptreact",
"prefix": ["component", "styled-component"],
"body": [
"/** @jsx jsx */",
"import { css, jsx } from \"@emotion/core\"",
"import React from \"react\"",
"",
"/**",