Comments (6)
Thanks for this issue - while I see you have some example code above it would be great if you could put together a min-repro with stackblitz someone can dig into.
from fast.
Hi @chrisdholt I tried to replicate the issue but cannot do it on Stackblitz (it's working fine). It seems that the issue relies somewhere in the build part of my application. I am using the esbuild and i am bundling dependencies of my package as seperate JavaScripts. When I bundle everything in single JS everything works as expected, but when i have the fast-element imported over importmap it ignores reactive totally for some reason. I will try to investigate more to find where the issue comes from
from fast.
Hi @chrisdholt I tried to replicate the issue but cannot do it on Stackblitz (it's working fine). It seems that the issue relies somewhere in the build part of my application. I am using the esbuild and i am bundling dependencies of my package as seperate JavaScripts. When I bundle everything in single JS everything works as expected, but when i have the fast-element imported over importmap it ignores reactive totally for some reason. I will try to investigate more to find where the issue comes from
Thanks for this - I wonder if this could be related to the fact that state
is only currently available from an export path and not from the fast-element root?
from fast.
@chrisdholt Not sure i am importing it using @microsoft/fast-element/state.js
so i get seperate js in vendor folder for @microsoft/fast-element
and @microsoft/fast-element/state.js
and i am using import map like this to load them:
<script type="importmap">
{
"imports": {
"@microsoft/fast-element":"./vendor/_microsoft_fast-element.js",
"@microsoft/fast-element/state.js":"./vendor/_microsoft_fast-element_state.js",
}
}
</script>
JS loads fine but just reactive function does not react to changes for some reason. When i bundle everything in single JS it works normally. Still trying to figure out why
from fast.
Is there some special requirement for state.js in order for it to work? If I take a look at the reactive method in both, there is no difference but it only works when all is bundled together.
from fast.
Okay the issue is that apparently state.js has some references on fast-element itself internally so I guess that duplicate code in those two files is making a problem
from fast.
Related Issues (20)
- Using @microsoft/fast-react-wrapper with refs & accessing public element members HOT 2
- fix: Module `@microsoft/fast-element` has no exported member `InlineTemplateDirective` HOT 5
- rfc: add Declartive Bindings to fast-element
- fix: browser validation for inputs doesn't work in safari and firefox HOT 1
- feat: make repeat directive optionally accept a key
- fix: bad example in fast-foundation/src/accordion/README.md HOT 1
- fix: textarea missing attributes HOT 1
- rfc: [Breaking] rename `template` host directive to `host` HOT 3
- RFC: Removal of `@microsoft/eslint-config-fast-dna`
- RFC: Removal of `@microsoft/fast-benchmarks`
- RFC: Removal of `@microsoft/fast-colors`
- RFC: Removal of `@microsoft/fast-foundation` HOT 14
- RFC: Removal of `@microsoft/fast-react-wrapper`
- RFC: Removal of `fast-tagged-templates` HOT 1
- Removal of `@microsoft/fast-web-utilities` HOT 2
- RFC: FAST Project Re-alignment HOT 8
- fix: Add title property in web-components/fast-foundation/src/button HOT 1
- feat: provide `html.partial` and `css.partial` as standalone tagged template literals
- Non-unique ids when rendering multiple TextField components HOT 1
- fix(fast-element-1): some template bindings not properly being marked as volatile
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 fast.