본문 바로가기

전체 글

(293)
[java] Random cannot be resolved to a type Exception in thread "main" java.lang.Error: Unresolved compilation problems: Randomc => 'Random cannot be resolved to a type'라는 에러메시지가 뜨는 경우 패키지가 import 되지 않았거나, 변수명이 다른 경우에 이런 에러를 출력 할수 있다.
자바 - 1.기초 변수명 설정 * 자바 및 이클립스 설치 후 터미널에서 version과 javc 출력해보고 이클립스 열어서 class형 파일을 만들어서 test 진행 package practice; public class Main { public static void main(String[] args) { //1.println 칸띄우기 System.out.println("hello world"); //숫자, 스트링의 개념 //System.out.print(10+2000+"200"); //System.out.println(10+2000+"200"); //2. 변하지않는 변수값(상수) 설정 : final int x = 30; x = 40; final int y = 30; //y = 20; =>주석 해제하고 print할 경우 경고 Syst..
[0]Warning: You provided a value prop to a form field without an onChange handler. This will render a read-only field. If the field should be mutable use defaultValue. Otherwise, set either onChange or readOnly. => input tag에 readOnly를 사용하거나, value를 defaultValue로 사용하도록 권장하는 warning 인것 같았다. 1.때문에 readOnly를 사용했더니 input 내 value를 수정할수가 없고, 2.defaultValue로 변경시 계속해서 비동기로 데이터 불러올때 초기 데이터값으로만 남아있었다. 때문에 비동기로 데이터를 불러올때 데이터 불러오기전 빈배열로 초기화 로직을 추가해서 해결하였다. const Book = () => { const [bookinfo, setBookinfo] = useState([]); const getInformation = (value) =>{ setBookInfo([]) axios.get( .. ) } return ( [...] {bookinfo...
네이버검색api cors 에러 해결 : No 'Access-Control-Allow-Origin' header is present on the requested resource. 참고링크: https://msyu1207.tistory.com/entry/React%EB%A1%9C-%EC%98%81%ED%99%94-%EC%A0%95%EB%B3%B4%EB%A5%BC-%EA%B2%80%EC%83%89%ED%95%B4%EB%B3%B4%EC%9E%90-%EB%91%90%EB%B2%88%EC%A7%B8-%EB%84%A4%EC%9D%B4%EB%B2%84-API-%EC%82%AC%EC%9A%A9-CORS-%EC%84%A4%EC%A0%95-%ED%95%98%EA%B8%B0#toc-%F0%9F%93%A2CORS%EB%A5%BC%20%EC%B2%98%EB%A6%AC%ED%95%98%EB%8A%94%20%EB%B0%A9%EB%B2%95%20ONE
인코딩 디코딩 사이트 참고 참고: http://www.hipenpal.com/tool/url-encode-and-decode-in-korean.php URL 인코더/디코더 - Hi!Penpal! 문자열을 Base64 방식으로 인코딩 또는 디코딩해줍니다. www.hipenpal.com 자바스크립트 인코딩 디코딩: 참고: https://twpower.github.io/113-uri-encode-decode-in-javascript
[0]redux-toolkit unwrap 사용시 에러 =>Error: Actions must be plain objects. Use custom middleware for async actions. 비동기 불러오는 도중 unwrap 사용하는데, 다음과 같은 에러가 떴다. 생각보다 바보같은실수였다. slice내부 함수를 페이지내의 함수와 동일한 이름으로 호출하여 반복 호출되어 생긴 오류였다. 혹시라도 같은 실수를 한 분이 계시다면 네이밍을 한번더 살펴 보시길..!
크롬 비밀번호 자동완성, 자동저장 기능해제
[0]Uncaught (in promise) TypeError: Cannot read properties of null (reading 'clientWidth') - react tailwindcss error 1. 해당 width를 적용하는 부분(ex: 데이터를 불러오는 부분, 클릭시 이벤트)에서 width와 관련된 태그내부 길이를 document.getById("").clientHeight로 동적 길이를 측정 후 => useState로 이벤트 실행시 길이 변경 2.tailwind에서 이벤트 발생시 변동되는 값의 경우 적용이 되지 않는 경우가 있다. tailwind css는 정적으로 알려진 클래스에 의존하기 때문에 작동하지 않을수 있다. 따라서 이럴 경우에는 style컴퍼넌트를 사용한다. 참고: https://stackoverflow.com/questions/73199212/change-class-attribute-dynamically-inline-with-tailwind