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

Dynamic Keys? #14

Open
AtlantaJones opened this issue Nov 18, 2019 · 0 comments
Open

Dynamic Keys? #14

AtlantaJones opened this issue Nov 18, 2019 · 0 comments

Comments

@AtlantaJones
Copy link

Unless I'm doing something wrong, it doesn't look like component keys can be set dynamically via prop vars?

Here's what I'm trying:

<scroll-view>
  <template slot-scope="visibility">
    <headlines
      :key="scrollKey"
      :title="title"
      :heading="heading"
      :subhead="subhead"
      :visible="visibility.scrollKey"
    ></headlines>
  </template>
</scroll-view>

Where scrollKey is a prop on the parent component. It works fine if I hard-code a key, but I have these appearing multiple times on a page, and they're always nested, so I can't hard-code a key each time.

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