tbreuss / mithril-by-examples

Learn Mithril.js by seeing, reviewing, and running up-to-date code examples
https://mithril-by-examples.js.org
MIT License
10 stars 8 forks source link

Make simple application 2.0.4 compatible #28

Closed tbreuss closed 3 years ago

tbreuss commented 3 years ago

The simple application requires version 1.1.6.

https://github.com/tbreuss/mithril-by-examples/blob/main/examples/simple-application.md

Make it work running version 2.0.4.

Screenshots:

Bildschirmfoto 2021-10-31 um 09 29 58 Bildschirmfoto 2021-10-31 um 09 30 18
namangirdhar16 commented 3 years ago

@tbreuss i would like to work on this issue. It's just i need a little more explanation of what needs to be done here. You can assign this to me.

tbreuss commented 3 years ago

@namangirdhar16 It would be nice if you could work on this. It looks like it was a function used, that isn't supported in v2.0.4 (see new screenshots in the issue)

It looks like this would fix the issue: https://mithril.js.org/migration-v1x.html#mrouteprefix

namangirdhar16 commented 3 years ago

@tbreuss cool i'll try my best!

namangirdhar16 commented 3 years ago

@tbreuss is this not counting towards hacktoberfest?

tbreuss commented 3 years ago

@tbreuss is this not counting towards hacktoberfest?

I thought it was an easy one.

But: Have you tried running the example in Flems (by clicking the appropriate button)? It ends up in e strange error.

To achieve this:

tbreuss commented 3 years ago

@tbreuss is this not counting towards hacktoberfest?

It should if finished (=merged) today.

namangirdhar16 commented 3 years ago

@tbreuss is this not counting towards hacktoberfest?

I thought it was an easy one.

But: Have you tried running the example in Flems (by clicking the appropriate button)? It ends up in e strange error.

To achieve this:

  • you have to run the website locally
  • you have to update the mithril version in the front matter of the edited example

Yes i ran it locally, in Flems it not showing any error like in the screenshot above mentioned by you, Here is the current screenshot:

image

namangirdhar16 commented 3 years ago

@tbreuss is this not counting towards hacktoberfest?

I thought it was an easy one.

But: Have you tried running the example in Flems (by clicking the appropriate button)? It ends up in e strange error.

To achieve this:

  • you have to run the website locally
  • you have to update the mithril version in the front matter of the edited example

Well, it's easy but if it counts towards hacktoberfest then it would be good 😅, if not then also it's great.

tbreuss commented 3 years ago

Yes i ran it locally, in Flems it not showing any error like in the screenshot above mentioned by you, Here is the current screenshot:

Can you please click one of the links in the right hand side of flems? I had some strange error which not occurs with version 1.1.6

namangirdhar16 commented 3 years ago

Yes i ran it locally, in Flems it not showing any error like in the screenshot above mentioned by you, Here is the current screenshot:

Can you please click one of the links in the right hand side of flems? I had some strange error which not occurs with version 1.1.6

It does not give error like mentioned by you, but it give something in console: image

tbreuss commented 3 years ago

Compare the behaviour with this one here (the original flems link from the official website) and you know what I mean.

https://flems.io/#0=N4IgzgpgNhDGAuEAmIBcIB0sxhAGhADMBLGXVAbVADsBDAWwjRAFVIAnAWQHsloMAVrgKxu1ROOYA3WuwAEbCPIC8c4AB1qc7XKjEw8VHIoBdPJp27utJABl9huYQCu1BMTEAKAJRqLlnXYIeGd2LXoMIIBHZwgDTw0tAOTGeAALXiN1EABxAFEAFWzzJOTLUKgskDT4eAAHMFQAeiag+gBaIIN22jriDDSlbgBrZ166rG56Jt7iJucOMGL-Mp0Ad2J0gGEgvnFiWihGuXh2WJLVgF9vFYCMdIhqTxc3eA8nrucoeF9E1ctFOwMHoDHJVJ9vhgkLR4LRbpZrrdLiVbrBQkFxEZgMjblBrEgjC93F5iEhfvDAsFQuFIhAYnF4AkKSlghkCXJsvkivhmQEKlUavVGi02p0GT0+gMhqNxpNprN5osmtk5ABqOSki7-bQbba7R5vQ7HU7nXmI0p3B5PIlvLwQn5+C2rQFYdEGsFye1mm4WnHUW5gWhSCCE1zEp7kp2UkJhOQRaKxeJ-bVx1mZDkgAAKLG5Wu1-IzgoazVaEA6XXgEv6g3YIzGdQmonlfUVSjAypAaoUHFd7Ax8Awmt5lmhsKMLrRfYNef+urSO2QBoORyMJogM4RPoRmkuIGRNAYTHQgPsBkEwhAonEBuksm7SlP8A9ye0YmI1E2457eJsj5nUmICA1lDV53h8R1ViCGNwk8bIMAWJR2hBeBinvIFkIwehemeMNbSeBD2EjFNPSpWN6FgkBaHgjgkIcdpNjLVDgDSIJCCqJpkE2DsuwIwckDwOQxFgIIYRDONIm4ZxEGBd9hmROReJId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OSXINJfS5AAGYylZJydQaiiFkLNWQu0Aw90YBGDCtQCAVS4yyCKUYfp-TSmtKSHUGwSB3wJM2aM9p4yCK0W6AxXyyYqqK2GAk4+1B2QoP6m82gqzCHsBkf4kJcgwDcD0EgOQKCkBgtWaIPE7AjAoMGXC1ZhywAK3ukYKqeJYDDFWT04pAztm7O0PssFRyjAAA4-n+IAKz4pOBAd67Q+CiHYDCd4iyxArLaf6c5NEZnXNQBkYM8hkxvUrAyhyzKxBGFcIDM+7LslnL5gLZqiLkWovRZiuJ6zelbLkFS16pzOXOKks1L5Py-kAqBSCsFSBPkOUBp0GwxAFhGEGdSwhtSwDEAAF7ErkCaxCbqEX6BVb6tVWLNU4u1TsvV-hCWHOoMcgJZSAm6tWfUxpia0kAFJ9W5MjmHLQtz7mPMks8mFEBy02u+UoEpZrAWkkteC-wfr2D2sOU6oZ1LIUORhXCwZgakW6RRRqagMr2hotweqpI2LNkDKjas2NPqo3JupcK+lcAxV4VZcsnN4y80Sv5UoY1RankvIgCSs9Z7RkuUgDAcM5AQCBJSagfxe4zDc1kuQKgBdDzMFqukdgpAXIVGYEWYU8xroPLlE0P9LFSAAAF-EYEQ4E6DmxYO83AQ9J6zAwDCWIHUDylwTCXCAA

namangirdhar16 commented 3 years ago

Compare the behaviour with this one here (the original flems link from the official website) and you know what I mean.

https://flems.io/#0=N4IgzgpgNhDGAuEAmIBcIB0sxhAGhADMBLGXVAbVADsBDAWwjRAFVIAnAWQHsloMAVrgKxu1ROOYA3WuwAEbCPIC8c4AB1qc7XKjEw8VHIoBdPJp27utJABl9huYQCu1BMTEAKAJRqLlnXYIeGd2LXoMIIBHZwgDTw0tAOTGeAALXiN1EABxAFEAFWzzJOTLUKgskDT4eAAHMFQAeiag+gBaIIN22jriDDSlbgBrZ166rG56Jt7iJucOMGL-Mp0Ad2J0gGEgvnFiWihGuXh2WJLVgF9vFYCMdIhqTxc3eA8nrucoeF9E1ctFOwMHoDHJVJ9vhgkLR4LRbpZrrdLiVbr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zMFqukdgpAXIVGYEWYU8xroPLlE0P9LFSAAAF-EYEQ4E6DmxYO83AQ9J6zAwDCWIHUDylwTCXCAA

Yeah, it's not working as desired after changing to version 2.0.4 and changing using m.route.prefix = "#".

tbreuss commented 3 years ago

This guide could be helpful: https://mithril.js.org/migration-v1x.html

tbreuss commented 3 years ago

Just fixed it, but thanks anyway!