This is just a regular paragraph. yen yen yen
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 SlackBot = require('slackbots'); | |
const axios = require('axios') | |
const dotenv = require('dotenv') | |
dotenv.config() | |
const bot = new SlackBot({ | |
token: `${process.env.BOT_TOKEN}`, | |
name: 'inspirenuggets' | |
}) |
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 urlSlug = (postTitle) => { | |
let postUrl = postTitle.toLowerCase().split(' '); | |
let postSlug = postUrl.join('-'); | |
return postSlug; | |
} | |
let postTitle = 'Handling Static Forms, The Client-side Way' | |
console.log(urlSlug(postTitle)); |
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
<form action="/thanks.html" name="Bolaji's form" method="POST" data-netlify="true"> | |
<div class="form-group"> | |
<label>Name:</label> | |
<input type="text" class="form-control" id="name" placeholder="Name"> | |
<div class="invalid-feedback"> | |
Name must be between 2 and 20 characters | |
</div> | |
</div> | |
<div class="form-group"> | |
<label>Email:</label> |
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
<form action="https://formspree.io/you@email.com" method="POST"> | |
<input type="hidden" name="_subject" value="Bolaji's Form"> | |
<input type="hidden" name="_next" value="/thanks.html" > | |
<div class="form-group"> | |
<label>Name:</label> | |
<input type="text" class="form-control" id="name" placeholder="Name"> | |
<div class="invalid-feedback"> | |
Name must be between 2 and 20 characters | |
</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
import React from "react" | |
import ReactDOM from "react-dom" | |
function App() { | |
const date = new Date() | |
const hours = date.getHours() | |
let timeOfDay | |
if (hours < 12) { | |
timeOfDay = "morning" |
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
class TodoApp extends React.Component { | |
constructor(props) { | |
super(props); | |
this.state = { items: [], text: '' }; | |
this.handleChange = this.handleChange.bind(this); | |
this.handleSubmit = this.handleSubmit.bind(this); | |
} | |
render() { | |
return ( |
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
let regex; | |
/* matching a specific string */ | |
regex = /hello/; // looks for the string between the forward slashes (case-sensitive)... matches "hello", "hello123", "123hello123", "123hello"; doesn't match for "hell0", "Hello" | |
regex = /hello/i; // looks for the string between the forward slashes (case-insensitive)... matches "hello", "HelLo", "123HelLO" | |
regex = /hello/g; // looks for multiple occurrences of string between the forward slashes... | |
/* wildcards */ | |
regex = /h.llo/; // the "." matches any one character other than a new line character... matches "hello", "hallo" but not "h\nllo" | |
regex = /h.*llo/; // the "*" matches any character(s) zero or more times... matches "hello", "heeeeeello", "hllo", "hwarwareallo" |
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
<!DOCTYPE html> | |
<html lang="en"> | |
<head> | |
<meta charset="UTF-8"> | |
<meta http-equiv="X-UA-Compatible" content="ie=edge"> | |
<meta name="viewport" content="width=device-width, initial-scale=1, viewport-fit=cover"> | |
<meta name="description" content="Simple weight converter"> | |
<title>Weight Converter</title> |
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
{ | |
"name": "Weight Converter", | |
"short_name": "weight converter", | |
"icons": [ | |
{ | |
"src": "img/icons/icon-72x72.png", | |
"sizes": "72x72", | |
"type": "image/png" | |
}, | |
{ |