meteor 개발진행 - 하라는 데로 했는데 페이지가 안뜬다!
자 여기까지 잘 따라왔는데, 갑자기 페이지가 안뜨고 빌드조차 되지않는다!
정상입니다.
수정해줘야 하는 부분이 몇가지 있는데,
server - main.js // main.js 추가해줍니다.
그럼 빌드가 됩니다!
그러나, 화면에 error 표시가 되네요!
router를 추가해줍시다.
여기서 폴더구조는
- client // 클라이언트 사용
ㄴview
ㄴ comn
ㄴ header
ㄴ header.html
ㄴ footer
ㄴ footer.html
ㄴ layout
ㄴ mainContents.html
- lib // 클라이언트, 서버 둘다 사용
ㄴ router.js
- server // 서버사용
ㄴ main.js
main.html
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=Edge">
<title>DZCommute</title>
</head>
<template name="mainLayout">
<a class="skipnav" href="#container">메뉴 건너뛰기</a>
<div id="wrap">
{{> header}}
<div id="container">
{{> yield}}
</div>
{{> footer}}
</div>
</template>
router.js
Router.configure({
layoutTemplate : 'mainlayout',
});
//mainContents
Router.route('/', {
name: 'mainContents',
});
mainContents.html
<template name="mainContents">
mainContents
</template>
header.html
<template name="header">
header
</template>
footer.html
<template name="footer">
footer
</template>
를 해줬는데도, 에러 발생!!!!!!!
에러를 찾아서 고치면 또 다른 에러가 발생하는 마법같은 상황!!
마치 윈도우 업뎃과 같았다.
결론부터 말하자면,
iron router는 오류가 있으니 kadira flow roter 사용해 -> iron router 쓸거야? 그럼 meteor 다운 그레이드해서 사용해! -> 어라 1.4버전이야? -> 그럼 meteor오류 있어, 1.6부터 오류 없을걸? 최신으로 업뎃해 -> 아 업뎃했어? 그럼 iron router 에러나니, kadira flow roter 사용해 ㅎㅎ
ㅋㅋㅋㅋㅋㅋㅋ 싫어, 난 iron router사용할거야.
이유는 이미 사용해본 맛집이고, 현재 실무에서는 vue랑 react를 사용해야 하기에,
실무에서 사용안하는 meteor의 새로운 기술을 추가로 익히고 싶지 않았다. (그냥 있는거 맛있게 쓸래)
그러러면, iron router의 심기를 건드리는 애들이 없어야 한다.
(의존성있는 package파일들 모두 버전이 맞아야 된다. )
뭐 하나라도 잘못되면
구글링해서 찾은 방법대로, 첨에는 부분적으로 의존성 맞게 수정해줬으나 계속 오류 발생.
구글링 해서 찾은 방법 : meteor add ecmascript@=0.7.3 ejson@=1.0.13 logging@=1.1.17 meteor@=1.6.1 shell-server@=0.2.3 standard-minifier-js@=2.0.0 mobile-experience@=1.0.4
실패.
결국, 모든 패키지를 다시 깔기로 했는데...
.meteor/versions 아래를 복붙!!
accounts-base@1.2.17
accounts-facebook@1.1.1
accounts-oauth@1.1.15
accounts-ui@1.1.9
accounts-ui-unstyled@1.2.1
allow-deny@1.0.5
autoupdate@1.3.12
babel-compiler@6.18.2
babel-runtime@1.0.1
base64@1.0.10
binary-heap@1.0.10
blaze@2.3.2
blaze-html-templates@1.1.2
blaze-tools@1.0.10
boilerplate-generator@1.0.11
caching-compiler@1.1.9
caching-html-compiler@1.1.2
callback-hook@1.0.10
check@1.2.5
ddp@1.2.5
ddp-client@1.3.4
ddp-common@1.2.8
ddp-rate-limiter@1.0.7
ddp-server@1.3.14
deps@1.0.12
diff-sequence@1.0.7
ecmascript@0.7.3
ecmascript-runtime@0.3.15
ejson@1.0.13
es5-shim@4.6.15
facebook-config-ui@1.0.1
facebook-oauth@1.3.2
fastclick@1.0.13
fortawesome:fontawesome@4.7.0
froala:editor@3.0.6
geojson-utils@1.0.10
hot-code-push@1.0.4
html-tools@1.0.11
htmljs@1.0.11
http@1.2.12
id-map@1.0.9
iron:controller@1.0.12
iron:core@1.0.11
iron:dynamic-template@1.0.12
iron:layout@1.0.12
iron:location@1.0.11
iron:middleware-stack@1.1.0
iron:router@1.0.13
iron:url@1.1.0
jquery@1.11.10
launch-screen@1.1.1
less@2.7.9
livedata@1.0.18
localstorage@1.0.12
logging@1.1.17
meteor@1.6.1
meteor-base@1.0.4
minifier-css@1.2.16
minifier-js@2.0.0
minimongo@1.0.23
mizzao:bootstrap-3@3.3.1_1
mobile-experience@1.0.4
mobile-status-bar@1.0.14
modules@0.8.2
modules-runtime@0.7.10
momentjs:moment@2.24.0
mongo@1.1.17
mongo-id@1.0.6
npm-mongo@2.2.24
oauth@1.1.13
oauth2@1.1.11
observe-sequence@1.0.16
ordered-dict@1.0.9
promise@0.8.8
random@1.0.10
rate-limit@1.0.8
reactive-dict@1.1.8
reactive-var@1.0.11
reload@1.1.11
retry@1.0.9
routepolicy@1.0.12
sacha:spin@2.3.1
service-configuration@1.0.11
session@1.1.7
shell-server@0.2.3
spacebars@1.0.15
spacebars-compiler@1.1.2
standard-minifier-css@1.3.4
standard-minifier-js@2.0.0
templating@1.3.2
templating-compiler@1.3.2
templating-runtime@1.3.2
templating-tools@1.1.2
tracker@1.1.3
ui@1.0.13
underscore@1.0.10
url@1.1.0
webapp@1.3.15
webapp-hashing@1.0.9
.meteor/packages 에 아래를 복붙!!
# Meteor packages used by this project, one per line.
# Check this file (and the other files in this directory) into your repository.
#
# 'meteor add' and 'meteor remove' will edit this file for you,
# but you can also edit it by hand.
meteor-base@1.0.4 # Packages every Meteor app needs to have
mobile-experience@1.0.4 # Packages for a great mobile UX
mongo@1.1.17 # The database Meteor supports right now
blaze-html-templates@1.0.4 # Compile .html files into Meteor Blaze views
reactive-var@1.0.11 # Reactive variable for tracker
tracker@1.1.3 # Meteor's client-side reactive programming library
standard-minifier-css@1.3.4 # CSS minifier run for production mode
standard-minifier-js@2.0.0 # JS minifier run for production mode
es5-shim@4.6.15 # ECMAScript 5 compatibility for older browsers.
ecmascript@0.7.3 # Enable ECMAScript2015+ syntax in app code
shell-server@0.2.3 # Server-side component of the `meteor shell` command
iron:router@=1.0.13
less@2.7.9
sacha:spin
froala:editor
accounts-ui
accounts-facebook
accounts-base
facebook-config-ui
momentjs:moment
mizzao:bootstrap-3
물론, 사용안하는 플러그인은 빼주셔도 됩니다.
굳이 이렇게까지 해서, iron router를 사용해야하나 싶지만...
일단은, 화면 정상 출력! 확인!
ㅠㅠ...