-
카테고리
-
세부 분야
프론트엔드
-
해결 여부
미해결
변수명에,
19.09.14 17:52 작성 조회수 108
1
카멜 스타일이랑 그냥 소문자로 시작하시는 경우가 있는데요, 어떤 기준이신지 궁금합니다.
대표적으로 아래의 경우, User, Comments, Images는 대문자로 시작하고 id , content는 소문자로 시작하는데요.
onSubmitForm() {
if (this.$refs.form.validate()) {
this.$store
.dispatch("posts/add", {
content: this.content,
User: {
nick: this.me.nick
},
Comments: [],
Images: [],
id: Date.now(),
createdAt: Date.now()
})
.then(() => {
this.content = "";
this.hideDetails = false;
this.success = true;
this.successMessages = "Post Success MSG";
})
.catch(() => {});
}
}
답변을 작성해보세요.
1
답변 1