Closed marhalish closed 6 years ago
Hello @marhalish ,
blaze-layout
package, or some of it's up-to-date forks?this.render()
method?@marhalish Filling an issue please follow our issue template:
I updated my question @dr-dimitru. Is there any other information you need?
Hello @marhalish ,
Thank you for the update on this. Yes, please, answer next questions:
BlazeLayout
and this.render()
ending up with the same result?console.log
inside .render()
callbackbody
I updated my question again with a screenshot. It seems the 'mainLayout' from the mainLayout.html template is displaying, but the appHeader, content, and appFooter does not dynamically display the given templates based on the templates passed in the routes.js folder. Why is this?
import
edthis.render()
method?@marhalish is this solved? If so, what is your solution?
Sorry, that was accident. I am using the templating tutorial now.
@marhalish please update this thread when you will find a solution
I followed the tutorial, but what goes into the main.html and main.js that are created by default? The tutorial creates an imports folder with an index.js, index.html, etc., but what is the new file structure?
what goes into the main.html and main.js that are created by default?
Imports, for each side
See project's structure at this demo project
I updated the entire app to the same file structure as the demo project. Now whenever I load up my application located here: (https://github.com/marhalish/slangtionary) on the localhost:3000 server the only thing showing on screen is the imported files from "app/client/core.js". If I go to "http://localhost:3000/home" or "http://localhost:3000/about" nothing is rendered but the same imported files from "app/client/core.js".
@marhalish it's because we're using per-route dynamic loading, see example here
I updated my routes.js and other files, but the content is not importing based on the routes. I included some more screenshots. Do you have any ideas?
@marhalish errors? exceptions?
@dr-dimitru no errors are showing in the server logs
Is there anything else I can look for?
FlowRouter is (mostly) Client package. Check browser's console for errors
Just for fun I took a look at your repo to see if I could find where the problem was. I've listed the things I found in order below:
There are multiple templates named 'notFound'.
about.html
, contact.html
and notFound.html
notFound
template. Each template should be defined only once, preferably in it's own file.body
definitions (one in each template), causing each template to always be rendered to the page.
body
definitions_mainLayout.html
contains {{ yield }}
not {{> yield }}
as per docs
{{ yield }}
with {{> yield }}
- Requires
blazeand
templating, or
blaze-html-templates` packages to be installed"
.meteor/packages
, ostrio:flow-router-extra@3.4.3
)I then added routes for about and contact which also worked fine
Here's the fork where I have done the above. https://github.com/coagmano/slangtionary/
@coagmano thanks a lot!
Issue with template
dependency can be fixed by placing it above ostrio:flow-router-extra
in .meteor/packages
file, as described here.
Thank you so much @dr-dimitru and @coagmano! #43 is what plagued the routing this whole time. I truly appreciate all the help, I owe y'all one.
Hey everyone!
I have looked through this code for at least 10+ hours attempting to discover why the routing is not working for my new meteor application that I'm building for the Steem blockchain and still no result. I've tried multiple file structures and followed multiple tutorials, but still it doesn't work.
I am using VeliovGroup/flow-router with BlazeLayouts on Meteor 1.8.2
I want to launch this project ASAP, but I can't move on until this issue is resolved. Any help at all is eternally appreciated.
This is an open-source project called Slangtionary located on GitHub here: https://github.com/marhalish/slangtionary
If you need anymore information I'll gladly provide it.
Errors
There are no errors in console log. When I start the meteor server the expected templates are not displaying, this is the issue. I have tried using this.render() but I still cannot get it working.
Versions
Browser
Brave Browser - V. 0.19.139 Firefox - V. 57.0.4. (64-bit)
Operating System
MacOs High Sierra V. 10.13.12
All Meteor Package Versions:
allow-deny@1.1.0 autopublish@1.0.7 autoupdate@1.3.12 babel-compiler@6.24.7 babel-runtime@1.1.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.3.1 caching-compiler@1.1.9 caching-html-compiler@1.1.2 callback-hook@1.0.10 check@1.2.5 ddp@1.4.0 ddp-client@2.2.0 ddp-common@1.3.0 ddp-server@2.1.1 deps@1.0.12 diff-sequence@1.0.7 dynamic-import@0.2.1 ecmascript@0.9.0 ecmascript-runtime@0.5.0 ecmascript-runtime-client@0.5.0 ecmascript-runtime-server@0.5.0 ejson@1.1.0 es5-shim@4.6.15 geojson-utils@1.0.10 hot-code-push@1.0.4 html-tools@1.0.11 htmljs@1.0.11 http@1.3.0 id-map@1.0.9 insecure@1.0.7 jquery@1.11.10 kadira:blaze-layout@2.3.0 -> Original KadiraHQ/Blaze-layout launch-screen@1.1.1 livedata@1.0.18 logging@1.1.19 meteor@1.8.2 meteor-base@1.2.0 minifier-css@1.2.16 minifier-js@2.2.2 minimongo@1.4.3 mobile-experience@1.0.5 mobile-status-bar@1.0.14 modules@0.11.0 modules-runtime@0.9.1 mongo@1.3.1 mongo-dev-server@1.1.0 mongo-id@1.0.6 npm-mongo@2.2.33 observe-sequence@1.0.16 ordered-dict@1.0.9 ostrio:flow-router-extra@3.4.4 promise@0.10.0 random@1.0.10 reactive-dict@1.2.0 reactive-var@1.0.11 reload@1.1.11 retry@1.0.9 routepolicy@1.0.12 shell-server@0.3.1 spacebars@1.0.15 spacebars-compiler@1.1.3 standard-minifier-css@1.3.5 standard-minifier-js@2.2.3 templating@1.3.2 templating-compiler@1.3.3 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.4.0 webapp-hashing@1.0.9
Here is a screenshot of my application code where I believe the problem may be. Is there something wrong with the setup currently that is causing the templates "appHeaderLayout", "appFooterLayout", and the "content" section to dynamically display depending on the given route in the routes.js file?