oncreate appears to be broken
See original GitHub issueOnCreate seems to be broken currently. When porting a rather large application from hyperapp@0.7
to hyperapp@0.9
I experienced a crash.
Broken Code [run]
const { h, app } = hyperapp
/** @jsx h */
app({
state: null,
actions: {
bug: element => element
},
view: (element, {bug}) => <h1 oncreate={bug}>{element ? 'yes' : 'no'}</h1>
})
Workaround [run]
const { h, app } = hyperapp
/** @jsx h */
app({
state: null,
actions: {
bug: element => element
},
view: (element, {bug}) => <h1 oncreate={data => setTimeout(() => bug(data), 0)}>{element ? 'yes' : 'no'}</h1>
})
Issue Analytics
- State:
- Created 6 years ago
- Comments:29 (17 by maintainers)
Top Results From Across the Web
Code in Android onCreate() method not working properly
I'm trying to make a really simple android game, and so far I have a method named startGame() which just plays a sound...
Read more >Android build error. MainActivity.java:7: error: cannot find ...
Android build error. MainActivity.java:7: error: cannot find symbol - onCreate(Bundle savedInstanceState) #111.
Read more >4. The Activity Lifecycle: Being an Activity - Head First Android ...
A new activity is created in its place. The activity is visible but not in the foreground. The onCreate() and onStart() methods get...
Read more >Activity | Android Developers
onCreate(Bundle) is where you initialize your activity. Most importantly, here you will ... All of this information appears back on the parent's Activity....
Read more >findNavController() fails in onCreate when NavHostFragment ...
But the real problem here is Android Studio showing warning for this setup suggesting to replace <fragment> with FragmentContainerView . In other words,...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
@jbucaran No, I don’t have time for OpenSource stuff right now. I’m working while being a full-time student.
@jbucaran Sorry to quote myself again, but please re-read my last comment.