Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Generate a top-level <project-name> component and put it in index.stache #269

Open
mjstahl opened this issue Oct 23, 2017 · 0 comments
Open

Comments

@mjstahl
Copy link
Contributor

mjstahl commented Oct 23, 2017

Description:

For a newly generated application we should do the following:

  1. Generate a <main_folder>/components/<project-name> component.
  2. Place this <project-name> component in the index.stache instead of a <h1>.

This occurred after conversations about a client project.

The app.js should only be responsible for three things:

  1. Rendering the appropriate application entry, whether that be the application itself (when their is a session), or a log in page, or something else the application may need.
  2. Manage the route
  3. Acquire and manage the session of the application.

With this addition an index.stache might look like:

<html>
  <head>
    <title>{{title}}</title>
  </head>
  <body>
    <can-import from="hello-world/styles.less" />
    <can-import from="hello-world/app" export-as="viewModel" />
    <can-import from="hello-world/components/hello-world />
    
    <hello-world />

    {{!--
    {{#if session}}
      <hello-world />
    {{else}}
      <login session:to="session" />
    {{/if}}
    --}}
    ...

Or something like that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants