Comments (4)
It looks like you don't use a template literal so opts
is not a template literal expression, but a part of the string.
How do you render your component?
from components.
I am using the code snippet from the Tonic example page (Chart).
I have inlined the Tonic code for TonicChart.
I have also tried "${new Date()}"
which you have in the Relative-Time example.
In both cases, the string does not get expanded and the component gets the string as opposed to the expression the string should evaluate to.
How should I write the options=
to get the expression evaluated?
from components.
<tonic-relative-time
date="${new Date()}"
refresh="1e4"
locale="en"
</tonic-relative-time>```
Is `new Date()` evaluated, attached to attribute `date` and passed to the component method?
OR
Is the string `"${new Date()}"` passed to the component method and this is where it is evaluated?
from components.
The code snippets for tonic-chart and tonic-relative-time are a bit misleading. They do not work as HTML snippets. They only work as inside template literals where the ${}
gets evaluated inside Javascript.
from components.
Related Issues (20)
- add attribute to control render before show
- create a scrollable component
- Add a way to force close a tonic-split HOT 1
- Migrate to ESM HOT 1
- Issue reRendering the TonicChart component HOT 2
- TonicRouter seems to have issues working with hash fragments
- how to run tests? HOT 1
- Checkbox click issue
- Tonic-Inline-Toaster appropriates image content and positions it as if it belonged to it's own icon
- issue calling reRender on button
- tonic-input without id causes value to be lost HOT 5
- Calling `reRender()` from an event handler has suprising behavior HOT 1
- Set up GitHub actions as CI HOT 3
- Support inline tonic-dialog HOT 2
- Refactor `windowed` to use a backing array interface HOT 3
- popover should be hidden on window resize
- Version badge on docs outdated
- Tonic dialog is not re render safe HOT 1
- Windowed: Allow text selection for the rows. HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from components.