| 일 | 월 | 화 | 수 | 목 | 금 | 토 |
|---|---|---|---|---|---|---|
| 1 | 2 | 3 | 4 | |||
| 5 | 6 | 7 | 8 | 9 | 10 | 11 |
| 12 | 13 | 14 | 15 | 16 | 17 | 18 |
| 19 | 20 | 21 | 22 | 23 | 24 | 25 |
| 26 | 27 | 28 | 29 | 30 |
- 신기술은
- ERR_CERT_AUTHORITY_INVALID
- 코틀린
- kotlinc
- HTML 자바스크립트 태그제거
- 리엑트
- 해볼게
- 무과금살아남기
- react
- 복붙하기좋은
- 정규식
- ReactRouter 4
- ubuntu_rg_cpu_100%
- checkupdates
- 모던디자인테마
- 편하게쓰자
- 야근은결국승리
- 리엑트라우터 구버전 살리기
- 시플플은영원하구나
- 공부할시간이
- vscode 수동업데이트
- ReactRouter6 다운그레이드
- 나의야근
- ReactRouter withRouter
- 날이새도록
- 반갑지는않아
- 선택했을까
- 안할수가없네
- 자바스크립트
- VSCode
- Today
- Total
목록Service Developments (13)
필사(筆寫)
const autoImportReactPlugin = { name: 'auto-import-react', setup(build) { build.onLoad({ filter: /\.[jt]sx$/ }, async (args) => { const fs = require('fs').promises; const source = await fs.readFile(args.path, 'utf8'); const reactImport = `import * as React from 'react';`; const hasJsx = source.includes(''); const contents = hasJsx ? reactImport + '\n'..
1. DISK IO 잡아먹으면서 들어가는 방법 import { promises as fs } from 'fs';import { pathToFileURL } from 'url'; const tempFilePath = './temp-bundle.mjs';await fs.writeFile(tempFilePath, bundledCode);const { default: Example } = await import(pathToFileURL(tempFilePath).href);await fs.unlink(tempFilePath); 2. 메모리에 담고 처리하는 방법import { createRequire } from 'module';const require = createRequire(import.meta.url);c..
https://nodejs.org/api/vm.html VM (executing JavaScript) | Node.js v22.5.0 DocumentationVM (executing JavaScript)# Source Code: lib/vm.js The node:vm module enables compiling and running code within V8 Virtual Machine contexts. The node:vm module is not a security mechanism. Do not use it to run untrusted code. JavaScript code can be compilednodejs.org 가끔 코어단 설계시 사용하는 vm 설계 구문 메모해두기engine.vm = a..
정상적으로 nginx 새버전이 설치되었다면1.27.1 은 http3 가 빌드하지 않고도 배치되어 있다. nginx -V 2>&1 | grep -o with-http_v3_module 아래와 같이 1.18 미리 설치되어 있다면 정리하고. ubunutu 20, 22 계열 기본 설치된 nginx 1.18 삭제 방법우분투에 기본적으로 설치 한 뒤 배치되어 있는 1.18을 삭제하는 방법은 아래와 같다. sudo apt remove nginx nginx-common nginx-core sudo apt purge nginx nginx-common nginx-core sudo apt remove nginx nginx-common sudo apt purgewesias7.tistory.com 간단하게, http {..
우분투에 기본적으로 설치 한 뒤 배치되어 있는 1.18을 삭제하는 방법은 아래와 같다. sudo apt remove nginx nginx-common nginx-core sudo apt purge nginx nginx-common nginx-core sudo apt remove nginx nginx-common sudo apt purge nginx nginx-commonsudo apt autoremove sudo apt update 이렇게 하면 보통 정리된다. nginx-full, nginx-core 등을 설치했다면 위 방식 활용해서 삭제할 것지운 뒤 다시 재설치하면 현재 nginx 공식 홈페이지에 게재된 stable 버전으로 설치 된다. 2024년 07월 19일 기준으로는 1.27.1 버전이 설치..
Error: ENOENT: no such file or directory, uv_resident_set_memory 리눅스/우분투 계열에서 위와 같은 메시지와 함께 nodejs express 데몬이 종료된다면, 여러가지 nginx 설정도 중요하지만 우분투에서 파일 접근 디렉티브 조정이 필요하다. $ulimit -n 했을때 1024라면, 파일 접근 가능 횟수가 부족할 수 있음으로서버 성능에 따라서 조정을 해주는 것이 맞다. root 계정을 사용할 때와 sudo root 처리하는 경우 둘다 작업해줘야 한다.ulimit 설정 이후 터미널을 종료하고 다시 들어와서 ulimit -n 숫자가 올바르게 변화했음을 체크해야 한다. 아스테리크를 써서 전역적인 설정은 아래와 같이 하며 sudo nano /etc/secur..
nodejs에서 GC는 정말 빠르게 잘 대응해줘야하는 녀석중 하나인데 좁은 메모리 환경을 보다 효율적으로 잘 쓰게 해주는 녀석이기도 하기에 아래와 같은 아주 짧막한 팁을 적어본다. let output = [....].join('') 간단한 배열 메모리 있다치면, 이를 비우는 과정도 중요한 관점이지만 이미 join을 통해 string 객체로 변환되어서 주소에 배정되었다 가정하면. output = null 이렇게 배정하면 해당 주소 기준으로 메모리를 끊는 과정은 있지만 GC가 다녀가기 전까지 배열로 변환했던 string 값은 메모리에 보관되는 경우가 있다. output = undefined 을 쓰자. 그럼 GC가 쓰레기로 판정후 해당 데이터를 지우러 빨리 와준다. 이는 다처리 구간에서 무척이나 아주 강렬하게..
npm install eslint --save and --save-devThe difference between --save and --save-dev may not be immediately noticable if you have tried them both on your own projects. So here are a few examples...Lets say you were bulding an app that that used the moment package to parse and display dates. Your app is a scheduler so it really needs this package to run, as in: cannot run without it. In this case..
https://socket.io/get-started/chat/ 의 예제를 통해서 체험 해봤다. 다른 것은 모르겠는데, 확실히 그 당시 편리하다고 이야기 했을만큼 잘 구성했다.코드 영감이 들었던 부분은 emit을 정말 잘 활용했다는 점. 규칙성 있게 이점을 잘 활용했고 깔끔했다.express의 emit 중 채팅으로 어떻게 보면 퇴화되었지만, 집중화된 기능 만큼은 참 재밌다. room이라는 통칭은 챗 서비스 개발에 특화야 라고 말해주는 것 같아서 활용도가 매우 높다는 점을 느꼈다.이점을 십분 활용 한다면, Chatbot API와 연계해서 쓰는 작업을 하면 좋을 듯 하다. 테스트앱 : https://github.com/wesias7/hello-socketio 직접 테스트해보고 싶다면 제일 위의 링크를 들어가..
http://sass.js.org/ 공식 홈페이지에 보면 libsass 라고 써있는 메뉴가 상단 우측에 보인다. 요녀석을 클릭하면, Playground Online 반가운 온라인 체험공간이 열린다. 놀이터다. 사스 같은 경우 여러 문법이 CSS를 보다 반복하지 말고 구조적으로 짜서 써라 라고 하는거니 반갑게 하면된다. 보통 그 요리 소재는 bootstrap4 기반으로 연습하다보면 확실히 실력이 빨리 늘 것이다. 매번 부트스트랩의 기능을 따다 쓰다, 이번엔 커스텀하기로 했다. Node Javascript 선호자라면 https://www.npmjs.com/package/node-sass Fully Javascript 선호자라면 http://sass.js.org 여기서 마음 껏 테스트해 볼 수 있다. http..