Skip to content

Instantly share code, notes, and snippets.

View jyydev's full-sized avatar
:octocat:
✌(≧◠ᴥ◠J)✌ + ✌(Y◠ᴥ◠≦)✌ = :octocat: :octocat:

JY jyydev

:octocat:
✌(≧◠ᴥ◠J)✌ + ✌(Y◠ᴥ◠≦)✌ = :octocat: :octocat:
View GitHub Profile
@jyydev
jyydev / README.md
Last active April 16, 2025 21:21
VSCode -> autocomplete -> disable & turn off autocomplete on dot . period

Disable (turn off) autocomplete on dot . period for VSCode

Most people do not want to have autocompletion when they press the dot key, which should be disabled by default in VSCode.

Below shows 2 ways to turn this off.

Method 1:

  1. Go to VSCode setting and search for:
editor.acceptSuggestionOnCommitCharacter
@jyydev
jyydev / README.md
Last active June 29, 2021 07:56
VSCode open editors setting

VSCode open editors setting

Search in setting: explorer.openEditors.visible

Default

Explorer › Open Editors: Visible
@jyydev
jyydev / README.md
Last active June 29, 2021 06:27
demo gist api

Demo Gist API

  • Type: full code example
  • Language: javascript, node.js
  • Demo: update an existing gist:
    • create a new file in a gist
    • edit the content of a gist file

Requirements

  • Github personal access token
  • Run: npm i @octokit/core in terminal
@jyydev
jyydev / README.md
Last active June 29, 2021 05:16
github api urls

Github API urls

  • https://api.github.com/repos/<USERNAME>/contents/
  • https://api.github.com/repos/<USERNAME>/contents/<REPO>/<FOLDER/FILE...>

Raw

  • https://raw.githubusercontent.com/{USERNAME}/{FOLDER,FILE...}
@jyydev
jyydev / test.json
Last active June 29, 2021 05:55
description test1
[
{
"a":"a",
"b":"b"
},
{
"c":"c",
"d":"d"
}
]
@jyydev
jyydev / README.md
Last active June 29, 2021 03:21
gist template readme

Catch fetch() error

  • type: full code example
  • language: javascript
  • function: fetch()
  • demo: catch error

2 files

@jyydev
jyydev / README.md
Created June 29, 2021 02:54
.env file priority

.env file priority for environment variables

.env.development.local > .env.development > .env.local > .env

.env.production.local > .env.production > .env.local > .env

If the same variable exists, higher priotiy (on the left) will overwrite the value of the lower priority.

@jyydev
jyydev / README.md
Last active June 29, 2021 02:06
fetch() catch error

Catch fetch() error

  • type: full code example
  • language: javascript
  • function: fetch()
  • demo: catch error

2 files

@jyydev
jyydev / README.md
Last active June 29, 2021 00:12
Chome DevTools keyboard shortcuts
@jyydev
jyydev / index.html
Created June 28, 2021 14:25
Parallax scroll animation
<svg xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 750 500" preserveAspectRatio="xMidYMax slice">
<defs>
<!-- Scene 1 Gradient -->
<linearGradient id="grad1" x1="-154.32" y1="263.27" x2="-154.32" y2="374.3"
gradientTransform="matrix(-1, 0, 0, 1.36, 231.36, -100.14)" gradientUnits="userSpaceOnUse">
<stop offset="0.07" stop-color="#9c536b" />
<stop offset="0.98" stop-color="#d98981" />
</linearGradient>
<radialGradient id="bg_grad" cx="375" cy="-35" r="318.69" gradientUnits="userSpaceOnUse">
<stop offset="0.1" stop-color="#F5C54E" id="sun" />