Skip to content

Instantly share code, notes, and snippets.

View spences10's full-sized avatar
💭
SvelteKit is bae!

Scott Spence spences10

💭
SvelteKit is bae!
View GitHub Profile
@spences10
spences10 / interviewQuestions.md
Last active December 29, 2022 05:18
List of questions to ask employers at interviews

Interview Questions You Should Ask

Why me as a candidate?

I like to ask this one so you can gauge if you're just there to make up the numbers or if they're really interested in you and have read your CV/profile.

How can I best prepare for this role before starting?

This question lets them know you're excited not only about the role, but also about starting and self-learning! You're a go getter and that's great! Plus, having this answered will give you a jump start on being prepared for your first day.

@spences10
spences10 / recruiter-reply.md
Last active May 1, 2018 09:34
recruiter reply

Hey {recruiter-name},

Thanks for getting in touch about the {role} at {company} you're interested in talking to me about.

Before we have a chat I'd like to know a bit about the role and the company first, take this as an initial discussion, please could you tell me.

  • What's the work-life balance?
@spences10
spences10 / script.md
Created April 26, 2018 09:18
Set up CentOS on Vagrant for CrafterCMS

Install dependencies on CentOS

For Crafter > Java, Git

use root:

sudo -i
# switch back with 'su - vagrant' when needed
@spences10
spences10 / script.md
Last active April 26, 2018 11:28
Install fish shell on CentOS via Vagrant

Install fish and oh my fish on CentOS

If you haven't updated to the latest version of git take a look at this SO post on [installing Git on CentOS] also take a look at the [full post here] for installing fish on other OS'

# switch back with 'su - vagrant' or preferred user when needed
sudo -i
cd /etc/yum.repos.d/
# install wget
yum -y install wget
@spences10
spences10 / script.md
Created April 26, 2018 09:12
Install fish shell on CentOS via Vagrant

Install fish and oh my fish on CentOS

If you haven't updated to the latest version of git take a look at this SO post on [installing Git on CentOS]

# switch back with 'su - vagrant' or preferred user when needed
sudo -i
cd /etc/yum.repos.d/
# for CentOS 7
wget http://download.opensuse.org/repositories/shells:fish:release:2/CentOS_7/shells:fish:release:2.repo
export const Button = styled.button`
font-size: 1rem;
border-radius: 5px;
padding: 0.25rem 1rem;
margin: 0 1rem;
background: transparent;
color: ${props => props.theme.primary};
border: 2px solid ${props => props.theme.primary};
${props =>
@spences10
spences10 / slugIt.js
Last active March 30, 2018 12:44
Slug helper!
export const slugIt = text => {
if (!text) return
return text
.toString()
.toLowerCase()
.replace(/\s+/g, '-') // Replace spaces with -
.replace(/[^\w\-]+/g, '') // Remove all non-word chars
.replace(/\-\-+/g, '-') // Replace multiple - with single -
.replace(/^-+/, '') // Trim - from start of text
.replace(/-+$/, '') // Trim - from end of text
@spences10
spences10 / README.md
Last active March 22, 2018 17:16
Readme pattern

README pattern

Optimal README layout from Kent Dodds [source]:

  1. Title + tagline + logo?
  2. Badges
  3. The problem
  4. The solution
  5. TOC
  6. Installation
@spences10
spences10 / fontFace.js
Last active March 2, 2018 18:35
styled-components helper function
// credit: https://github.com/styled-components/styled-components/issues/233#issuecomment-292602734
export function fontFace(name, src, fontWeight = 'normal', fontStyle = 'normal'){
return `
@font-face{
font-family: "${name}";
src: url(${require('../../public/fonts/' + src + '.eot')});
src: url(${require('../../public/fonts/' + src + '.eot')}?#iefix) format("embedded-opentype"),
url(${require('../../public/fonts/' + src + '.woff')}) format("woff"),
const originalArray = [1, 2, 3];
const newArray = originalArray.map(item => item * 2);
console.log(newArray);