Formatting not working on page reload (looking for fallback)
drale2k opened this issue · comments
On an initial page load or page reload, the formatting is not working (Using Rails + Turbolinks). I used to solve this by calling updateNowElements
directly but now that Rails 6 switch to webpacker, i'd like to know how to access updateNowElements
after importing time-elements via
import timeElements from 'time-elements/dist/time-elements.js'
updateNowElements
is not supposed to be a public API, this should be better resolved from the root cause. Do you have page that has this problem that we can investigate? and can you try window.customElements.upgrade(el)
?