I am trying to show a dom-if template only to some users, but I don't know how to do it. Here is a pseudocode of what I am trying to do:
<template is="dom-if" if="{{user.isAdmin}}" restamp="true">
<hr />
<h1>Add new conference:</h1>
<paper-input
id="title"
label="Título"
type="text"
name="title">
</paper-input>
<paper-fab id="saveFab" icon="cloud-upload" on-tap="add"></paper-fab>
</template>
<script>
Polymer({
is: 'my-conferences',
properties: {
data: Array,
user: Object,
},
...
Where "user" is the object that I got from the <firebase-auth>
element. Something like user.isAdmin is what I would like to achieve.
Any ideas? Thank you!