Skip to content

Instantly share code, notes, and snippets.

Chase Isley theonlychase

Block or report user

Report or block theonlychase

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
@theonlychase
theonlychase / linear-regreession
Last active Nov 15, 2019
Predict download times, given the size of the download.
View linear-regreession
## Predicting the duration of a download
- Pattern of the workflow
1. Get training data
2. Convert data to tensors
1. Data objects must be represented as tensors, so they can be fed to the model
3. Create the model
1. Build a simple linear model with Keras-compatible Tensorflow layer primitives
2. trainable function mapping input data to things we are trying to predict
1. In this example, the input data and the prediction targets are both numbers
View tensor-flow
- Symbolic AI
1. Handcrafting a sufficiently large set of explicit rules for manipulating knowledge and making decisions
2. Dominant paradigm in AI from 1950s to 1980s
3. symbolic AI relies on hard-coding knowledge and rules
4. Rules and Data -> Classical Programming -> Answers
1. Artificial Intelligence
1. The effort to automate intellectual tasks normally performed by humans.
2. Machine Learning
View typescript-fundamentals
## What is TypeScript?
1. Open source typed, syntactic superset of JS.
2. Compiles to readable JS
1. Has no runtime part/component.
1. The types disappear in a build step
2. Think of it as a static analysis tool that does a lot of checking on your codebase
3. When you have a build you're sending to users, or that you're running in node.js, none of that type checking is there
4. There's no cost at runtime. It will not slow the app down.
View http
## What is HTTP?
1. Hyper Text Transfer Protocol
2. Communication between web servers and clients
3. HTTP Requests / Responses
4. Includes Header and Body
## Important Status Codes
1. 1.xx - Informational
View graphql
## Creating Schemas with SDL
1. Schema Definition Language
1. Instead of functions, uses a verbose, string based syntax for schemas
2. Can transform the syntax into many representations if needed
3. much easier to read
4. composable
2. Scalar and Object Types
1. Describe resources that will be used in queries and mutations
View vue-render-functions
### Render Functions
- They really shine when you need to dynamically decide which element you want to render
- For example, decicing if you wanted a button to use an anchor tag, button tag, or any other element and also be reusable
- you can't use `v-model` with render functions
@theonlychase
theonlychase / v-model
Last active Aug 7, 2019
v-model under the hood
View v-model
// with v-model
<input v-model="email" class="form-input" placeholder="you@example.com">
// without v-model
<input :value="email" @input="email = $event.target.value" class="form-input" placeholder="you@example.com">
data() {
return {
email: 'test@test.com'
}
View vue-reactivity
## Vue Reactivty System
#### Step 1
1. Create state object and create function to render `y` to html
```
<h1 id="y"></h1>
let state = { x: 1 };
View mini-data-observer
// Object.defineProperty - https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object/defineProperty
function convert(obj) {
Object.keys(obj).forEach(key => {
let internalValue = obj[key];
Object.defineProperty(obj, key, {
get() {
console.log(`getting key "${key}": ${internalValue}`);
return internalValue;
View update-npm
## Steps
1. Make sure local storybook is updated
1. `git fetch`
2. `git pull`
2. Make sure your local npm package is updated
3. Remove the file/folder that has been updated in storybook
4. Replace the removed files with the updated files in storybook
5. Update the version # of package.json
You can’t perform that action at this time.