Skip to content

Instantly share code, notes, and snippets.

View shoveller's full-sized avatar

cinos shoveller

  • SEOUL, SouthKorea
  • 01:52 (UTC +09:00)
View GitHub Profile
@shoveller
shoveller / cursor-agent-system-prompt.txt
Created March 17, 2025 04:10 — forked from pchaganti/cursor-agent-system-prompt.txt
Cursor Agent System Prompt (March 2025)
You are a powerful agentic AI coding assistant, powered by Claude 3.5 Sonnet. You operate exclusively in Cursor, the world's best IDE.
You are pair programming with a USER to solve their coding task.
The task may require creating a new codebase, modifying or debugging an existing codebase, or simply answering a question.
Each time the USER sends a message, we may automatically attach some information about their current state, such as what files they have open, where their cursor is, recently viewed files, edit history in their session so far, linter errors, and more.
This information may or may not be relevant to the coding task, it is up for you to decide.
Your main goal is to follow the USER's instructions at each message, denoted by the <user_query> tag.
<communication>
1. Be conversational but professional.
@shoveller
shoveller / postbodyEnc.md
Created September 24, 2023 04:50 — forked from jays1204/postbodyEnc.md
Http Method는 POST, Content-Type이 application/x-www-form-urlencoded인 경우 body를 encoding하는게 맞을까?

요즘의 Request

RestFul API를 사용하며 json을 많이 사용하게 됨에 따라 요즈음의 request의 Content-Type은 대부분이 application/json인 것이 많다.

아니면 파일 첨부를 위해 multipart/*를 사용한다. application/x-www-form-urlencoded는 form에서 default로 사용되는 것 이외에는 사실 잘 사용하지 않는 편으로 보인다.

요새 자주 사용하지 않지만, 하지만 여전히 application/x-www-form-urlencoded를 사용하는 경우가 존재한다.

Content-Type이 다름에 따라 뭐가 달라지겠느냐 하겠지만 다른 점이 분명히 있다.

@shoveller
shoveller / UT.json
Created August 12, 2022 00:42
CSS Grid Overlay - settings
[
{
"columns": 4,
"margins": 24,
"gutters": 8,
"from": 320,
"to": 599
},
{
"columns": 8,
@shoveller
shoveller / README.md
Created March 1, 2022 05:29 — forked from ngryman/README.md
intellij javascript live templates

intellij javascript live templates

Just a dump of handy live templates I use with IntelliJ. They should also work with WebStorm.

How to

  • Go to settings.
  • Search for live templates.
  • Under the javascript section you should be able to manage your templates.
@shoveller
shoveller / App.tsx
Last active January 21, 2022 18:07
useState의 대안으로 useReducer 사용하기
import {useCountContext} from "./store/counter";
import './App.css'
const Viewer = () => {
const {count} = useCountContext()
return <p>
count is: {count}
</p>
}
@shoveller
shoveller / sw-await.js
Created October 28, 2020 05:55 — forked from bakoushin/sw-await.js
Service Worker: Promises vs Async/Await
const version = 1;
const appPrefix = 'myApp-';
const staticCacheName = appPrefix + 'static-v' + version;
const imagesCacheName = appPrefix + 'content-imgs';
var allCaches = [
staticCacheName,
imagesCacheName
];
self.addEventListener('message', event => {
@shoveller
shoveller / oop.js
Last active April 4, 2018 04:20
oop로 설계한 http 서버 프로그램
const http = require('http');
const url = require('url');
const querystring = require('querystring');
class MyServer {
constructor(req, res) {
this.req = req;
this.res = res;
this.body = '';
this.params = {};
@shoveller
shoveller / traditional.js
Last active April 4, 2018 04:20
전통적인 http 서버의 구현 예
const http = require('http');
const url = require('url');
const querystring = require('querystring');
const onRequest = (res, method, pathname, params) => res.end(JSON.stringify(params));
http.createServer((req, res) => {
const method = req.method;
const uri = url.parse(req.url, true);
const pathname = uri.pathname;
@shoveller
shoveller / range.js
Created March 30, 2018 07:39
제네레이터로 구현한 레인지 함수
function* range(start, end, step = 1) {
for (let value = start; (step > 0 ? value <= end : value >= end); value = value + step) {
yield value;
}
}
for (const val of range(0, 10, 3)) {
console.log(val); // 0 1 2
}
@shoveller
shoveller / range.js
Last active March 30, 2018 08:22
커스텀 이터레이터로 구현한 레인지 함수
function range(start, end, step = 1) {
const iterable = {
[Symbol.iterator]() {
let value = start;
const iterator = {
next() {
value = value + step;
let done = value === end + step;
if (done) {