Thief of Wealth
Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core
개발/Web Programming 2020. 7. 31. 17:37

Error: Requires Babel "^7.0.0-0", but was loaded with "6.26.3". If you are sure you have a compatible version of @babel/core, it is likely that something in your build process is loading the wrong version. Inspect the stack trace of this error to look for the first entry that doesn't mention "@babel/core" or "babel-core" to see what is calling Babel 갑자기 nodejs 서버를 실행하려는데 저런에러가 뜬다면 babel버전문제이다. y..

SPA란?
개발/Web Programming 2020. 7. 30. 16:52

이 포스트는 https://velopert.com/3417 react-router :: 1장. 리액트 라우터 사용해보기 | VELOPERT.LOG 이 튜토리얼은 3개의 포스트로 나뉘어진 이어지는 강좌입니다. 목차를 확인하시려면 여기를 참고하세요. SPA 란? Single Page Application (싱글 페이지 어플리케이션) 의 약자입니다. 말 그대로, 페이지 velopert.com 를 필사한 글입니다. SPA란? Single Page Application 의 약자이다. 즉, 페이지가 1개인 어플리케이션을 말한다. 전통적인 웹어플리케이션의 구조는 여러페이지로 이루어져있지만, 유저가 요청할 때 마다 페이지가 새로고침되어서 페이지를 로딩할때마다 서버로부터 리소스를 전달받아 해석 후 렌더링을 한다. HTM..

[Nodejs] 기본기 2
개발/Web Programming 2020. 7. 30. 14:10

RESTful API REST는 Representational State Transfer의 약자로서, www와 같은 하이퍼 미디어에서 시스템을 위한 소프트웨어 아키텍쳐 중 하나이다. REST 서버는 클라이언트가 http프로토콜을 사용해서 서버의 정보에 접근 및 변경을 가능하게 한다. 여기서 정보는 text, xml, json 형식으로 제공된다. http 메소드 REST 기반 아키텍쳐에서 자주 사용되는 4가지 메소드는 다음과 같다. 1. GET 2. PUT 3. DELETE 4. POST

Refused to apply style from 'css/style.css' because its MIME type ('text/html') is not a supported stylesheet MIME type, and strict MIME checking is enabled.
개발/Web Programming 2020. 7. 30. 13:17

express static을 사용해서 public 폴더에 css폴더에 style.css를 적용하려고 하는데 저런 에러가 뜬다면? express static public의 경로를 인식하지 못한것이다. app.use(express.static(__dirname+ "/public")); 으로 바꿔서 시도해주자.

[NodeJs] 기본기 1
개발/Web Programming 2020. 7. 30. 12:29

본 포스트는 https://velopert.com/133 [Node.JS] 강좌 01편: 소개 | VELOPERT.LOG Node.js 가 뭐지? NodeJS 는 구글 크롬의 자바스크립트 엔진 (V8 Engine) 에 기반해 만들어진 서버 사이드 플랫폼입니다. 2009년에 Ryan Dahl에 의해 개발되었으며 현시점 (2016-02-07) 최신 버전은 v5.5.0 입니다 velopert.com velopert님 강좌를 필사하여 공부하기 위한 포스트입니다. NodeJS란? nodejs는 크롬의 javascript엔진(V8 engine)에 의해 만들어진 server side 플랫폼이다. 2009년에 ryan dehl에 의해 개발되었다. 사람들의 오해. nodejs는 웹서버가 아니다. node 자체로는 아무것..

CRA error...
개발/Web Programming 2020. 7. 29. 17:53

정상적으로 npx create-react-app my-app을 실행했는데 폴더안에 src, public 폴더가 없고 에러로 template을 불러올 수 없다고 뜨고, A template was not provided. This is likely because you're using an outdated version of create-react-app. Please note that global installs of create-react-app are no longer supported 겨우겨우 public, src 폴더를 생성하니까 1부터 9번까지의 방법이 나오면서 webpack version때문에 yarn start를 할 수 없다고 뜬다. 이때 해결방법은 create-react-app과 관련된 모든..

Mongoose populate가 동작하지 않는경우
개발/Web Programming 2020. 7. 28. 12:27

populate를 쓰면 ObjectId만 있던 field에 실제 값이 포함되어야 하는데, .populate("something") 을 사용할 경우 오히려 something: [] 으로 표시되는 경우가 있다. 그리고 TypeError: ID cannot represent value: 식의 에러가 뜰것이다. 이때에는 mongoose schema를 잘못정해준 것이다. 예를 들면 questions이라는 property에 Question의 array를 참조하게 하고 싶다면 아래와 같이 선언하는게 아니라, questions: { type: [Schema.Types.ObjectId], ref: 'Question' } 이렇게 선언해야한다. questions: [{ type: Schema.Types.ObjectId, r..

Error: There can be only one type named "Mutation".
개발/Web Programming 2020. 7. 27. 13:04

Mutation 문구가 중복되었을떄 발생한다. 1. 1개의 파일에 Query, Mutation 문구가 있는경우 Post.js Post { .... } extend type Query { .... } extend type Mutation { .... } extend 문구를 사용해서 파일별로 Mutation, Query를 여러번 선언할 수 있다. 2. Mutation, Query 파일 따로만들기 Mutation.js type Mutation { addPost():Boolean! addUser():Boolean! .... } 이렇게 1개의 Mutation 문구에 여러개 타입의 함수들을 선언할 수도 있다. 3. 여러개 타입을 여러개 Mutation, Query에 선언 이 경우는 1개의 Mutation, Quer..

profile on loading

Loading...