首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >流星路由错误:路径没有路由:/

流星路由错误:路径没有路由:/
EN

Stack Overflow用户
提问于 2016-04-25 03:34:46
回答 1查看 2.6K关注 0票数 4

我已更新流星1.3.2.4流星。面对这个问题。我还更新了最新版本的所有软件包。

错误:路径没有路由: /

我在两个环境"meteor“和"meteor run ”中都尝试了这两种方法,同样的错误将显示在控制台中。

我已经安装了以下软件包。

代码语言:javascript
复制
accounts-oauth                   1.1.12  Common code for OAuth-based login services
accounts-password                1.1.8  Password support for accounts
autopublish                      1.0.7  (For prototyping only) Publish the entire database to all clients
blaze-html-templates             1.0.4  Compile HTML templates into reactive UI with Meteor Blaze
cfs:gridfs                       0.0.33  GridFS storage adapter for CollectionFS
cfs:standard-packages            0.5.9  Filesystem for Meteor, collectionFS
ecmascript                       0.4.3  Compiler plugin that supports ES2015+ in all .js files
email                            1.0.12  Send email messages
es5-shim                         4.5.10  Shims and polyfills to improve ECMAScript 5 support
flowkey:bootstrap-tour           1.1.0  A Meteor.js / Blaze integration for bootstrap-tour
insecure                         1.0.7  (For prototyping only) Allow all database writes from the client
jquery                           1.11.8  Manipulate the DOM using CSS selectors
kadira:blaze-layout              2.3.0  Layout Manager for Blaze (works well with FlowRouter)
kadira:flow-router               2.12.1  Carefully Designed Client Side Router for Meteor
meteor-base                      1.0.4  Packages that every Meteor app needs
mobile-experience                1.0.4  Packages for a great mobile user experience
mongo                            1.1.7  Adaptor for using MongoDB and Minimongo over DDP
pauli:accounts-linkedin          1.3.1  Accounts service for LinkedIn accounts
service-configuration            1.0.9  Manage the configuration for third-party services
session                          1.1.5  Session variable
standard-minifier-css            1.0.6  Standard css minifier used with Meteor apps by default.
standard-minifier-js             1.0.6  Standard javascript minifiers used with Meteor apps by default.
themeteorchef:jquery-validation  1.14.0  jQuery Validation by jzaefferer, repackaged for Meteor.
tomi:upload-jquery               2.4.0  Client template for uploads using "jquery-file-upload" from blueimp
tomi:upload-server               1.3.4  Upload server for Meteor. Allows to save and serve files from arbitrary directory
tracker                          1.0.13  Dependency tracker to allow reactive callbacks
u2622:persistent-session         0.4.4  Persistently store Session data on the client
zimme:active-route               2.3.2  Active route helpers

我的routing.js公开= FlowRouter.group();

代码语言:javascript
复制
exposed.route('/', {
    triggersEnter: function () {
        if (Meteor.loggingIn() && typeof Meteor.userId() !== 'undefined') {
            FlowRouter.go("/dashboard");
        }
    },
    action: function () {
        BlazeLayout.render("mainTemplate", {content: "homePage"});
    }
});

exposed.route('/login', {
    triggersEnter: function () {
        if (Meteor.userId() !== null) {
            FlowRouter.go("/dashboard");
        }
    },
    action: function (params) {
        BlazeLayout.render("mainTemplate", {content: "login"});
    }
});
EN

回答 1

Stack Overflow用户

发布于 2020-02-29 13:07:50

我遇到了这个问题,并通过消除开发构建中存在的控制台错误来修复它。

想想看,我的开发构建成功的原因是JS文件为了生产而连接在一起,这意味着这个错误阻止了后续代码的运行。

因此,座右铭是,确保没有错误被抛出,因为它们会导致更多的问题,当连接文件生产!。

(所讨论的包是自动格式提示,但不要认为这与此特别相关。)

票数 0
EN
页面原文内容由Stack Overflow提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://stackoverflow.com/questions/36831628

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档