일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |
- DB Browser
- Python
- ReactDOM.render is no longer supported in React 18. Use createRoot instead
- 노드에 리액트 추가하기
- props
- Colaboratory 글자 깨짐
- JS 개념
- Spring-Framework
- vs code 내 node
- node.js로 로그인하기
- 모두의 파이썬
- 웹 게임을 만들며 배우는 리액트
- You are importing createRoot from "react-dom" which is not supported. You should instead import it from "react-dom/client"
- Concurrently
- 인프런
- react오류
- 타자 게임 만들기
- intellij
- intllij 내 Bean을 찾지 못해서 발생하는 오류
- node.js 설치
- googleColaboratory
- 따라하며 배우는 노드 리액트 기본 강의
- spring-boot
- react
- Do it 자바스크립트 + 제이쿼리 입문
- 거북이 대포 게임
- 자바스크립트
- 모던자바스크립트
- 리액트
- 계산맞추기 게임
- Today
- Total
프로그래밍 삽질 중
front부분(axios 있는 것) index.html 파일 내 js를 ts로 변환(진행중) 본문
* 목표
- 이전에 배포했던 영단어 version 2(자바스크립트(js))를 타입스크립트로(ts) 변환하는 것이 목적
* 첫 번째
▶ interface 사용
문제점 : 대다수 함수에 사용된 매개변수(english, korean, type, status(간간히))가 모두 string 값이나 interface로 사용 시 js로 변환하면 사라짐
▶ 제네릭을 이용해보자 생각함
▶ ts에서 이벤트 사용하기
문제점1 : js 내 document.querySelector는 ts에서 인식되지 않음
The property 'value' does not exist on value of type 'HTMLElement'
I am playing around with typescript and am trying to create a script that will update a p-element as text is inputted in a input box. The html looks as following: <html> <head> ...
stackoverflow.com
[typescript] 'HTMLElement'유형의 값에 'value'특성이 없습니다. - 리뷰나라
typescript를 가지고 놀고 있으며 입력 상자에 텍스트가 입력 될 때 p 요소를 업데이트하는 스크립트를 만들려고합니다. html은 다음과 같습니다. <html> <head> </head> <body> <p id="greet"></p> <form> <input id="na
daplus.net
▶ 해결책 3: https://www.typescripttutorial.net/typescript-tutorial/type-casting/
Type Casting
Summary: in this tutorial, you will learn about type castings in TypeScript, which allow you to convert a variable from one type to another type. JavaScript doesn’t have a concept of type casting because variables have dynamic types. However, every varia
www.typescripttutorial.net
문제점2 : js 내 event.target.dataset.type을 ts에서 인식하게 하고 싶으면?
▶ 해결책 1 : https://stackoverflow.com/questions/40676343/typescript-input-onchange-event-target-value
Typescript input onchange event.target.value
In my react and typescript app, I use: onChange={(e) => data.motto = (e.target as any).value} How do I correctly define the typings for the class, so I wouldn't have to hack my way around the t...
stackoverflow.com
▶ 해결책 2 : https://stackoverflow.com/questions/49631688/property-dataset-does-not-exist-on-type-eventtarget
Property 'dataset' does not exist on type 'EventTarget'
When trying to access the dataset on a button after a click, I get this^ error. linkProvider = (ev: React.SyntheticEvent<EventTarget>) => { console.debug('ev.target', ev.target.dataset[...
stackoverflow.com
* 문제점 : 'string | undefined' 형식의 인수는 'string' 형식의 매개 변수에 할당될 수 없습니다. 'undefined' 형식은 'string' 형식에 할당할 수 없습니다.
typescript에서 undefined value 처리하기
Typescript로 개발 하다보면, type이 맞지 않아 컴파일 에러가 자주 발생하곤 합니다. 그래서 여러 글들을 찾아보던 중 괜찮은 글이 있어서 번역을 해보았습니다. 번역이 매끄럽지 않더라도, 많은 이
blog.toycrane.xyz
* 문제점 :
TypeScript : Uncaught ReferenceError: exports is not defined
https://dev-minju.tistory.com/143
TypeScript : Uncaught ReferenceError: exports is not defined
문제 정의 : 코딩애플 Ts 강의 import/export 파트 따라 하는데 발생. 내 기억으로는 내가 뭐 따로 세팅한거 없고 pure 환경이었던 걸로 기억한다. type만 따로 빼서 기존의 컴포넌트에 import 하려 했는데
dev-minju.tistory.com
index:1 Uncaught TypeError: Failed to resolve module specifier "axios". Relative references must start with either "/", "./", or "../".
'axios' 모듈을 찾을 수 없습니다. 'moduleResolution' 옵션을 'node'로 설정하거나 'paths' 옵션에 별칭을 추가하려고 하셨습니까?
▶ 현재 여기서 계속 막히는 중
SyntaxError: import declarations may only appear at top level of a module. Using express, no webpack
I am trying to import a npm module in the front end script. It is saying modules must be on top level to import but it is at the top level from what I can tell. Maybe my web server is messing with my
stackoverflow.com
'과거 프로그래밍 자료들 > 프로젝트' 카테고리의 다른 글
카카오톡 로그인이 안 되는 경우(오류코드:KOE001) (0) | 2022.10.06 |
---|---|
[세팅] typescript 파일 연결(html에서 확인하기) (1) | 2022.09.21 |
[영어단어장 version2.0] 단어장 기능 및 로그인 보완, sns 기능 추가(pm2 stopped) (2) | 2022.09.08 |
ubuntu git 관련 오류 (0) | 2022.09.08 |
form내 action 경로가 실행되기 전 onSubmit 사용하기 (1) | 2022.09.07 |