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

<vaadin-router> DOM API (basic functionality) #47

Closed
vlukashov opened this issue Apr 25, 2018 · 1 comment
Closed

<vaadin-router> DOM API (basic functionality) #47

vlukashov opened this issue Apr 25, 2018 · 1 comment

Comments

@vlukashov
Copy link
Contributor

vlukashov commented Apr 25, 2018

As a developer I want to display different content on the page depending on the current URL.

As a Polymer developer I want to do that with HTML markup.

DoD:

  • the <vaadin-router> DOM API allows creating a router with a default router outlet, and setting a routes config with <vaadin-route> elements.
  • The route contents can be defined by a 'component' property on a <vaadin-route> element.
  • The route content can be defined by a <template> child of a <vaadin-route> element.
  • Changes to the DOM are handled and trigger a re-render if necessary:
    -- changes to the 'path' and / or 'component' properties / attributes
    -- adding / removing the child <template> element to a <vaadin-route>
    -- adding / removing child <vaadin-route> elements to a <vaadin-router>
  • add a demo for basic <vaadin-router> DOM API usage
  • the following snippet should work:
<vaadin-router>
  <vaadin-route path="/">
    <template>
      <h1>Home</h1>
    </template>
  </vaadin-route>
  <vaadin-route path="/users" component="x-user-list"></vaadin-route>
</vaadin-router>

The common DoD applies.

@vlukashov
Copy link
Contributor Author

Won't fix.

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

No branches or pull requests

1 participant