Skip to content

使用AngularJs 問題 #26

@z0890142

Description

@z0890142

目的

希望使用AngularJs 當作前端

遇到的問題

因為剛接觸express
上網爬文看到在express的app.js檔案裡使用
app.get('/', function(req, res) {
res.sendfile('./views/p1.html'); // load the single view file (angular will handle the page changes on the front-end)
});
這句可以讓node.js連接上我所編輯的AngularJs ,可是不知道為什麼我設了都沒有作用,如果我public的資料夾裡有index.html這個檔案他就會跑這個檔案,如果沒有她就會跑隨著專案產生的index.jade,我想請問一下是哪裡出了問題

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions