Frontmatter
| id | 6607 |
| title | Earthquakes tutorial still using model.Component instead of state.Provider |
| state | Closed |
| labels | bug |
| assignees | tobiu |
| createdAt | Apr 1, 2025, 12:27 AM |
| updatedAt | Apr 2, 2025, 4:34 AM |
| githubUrl | https://github.com/neomjs/neo/issues/6607 |
| author | tobiu |
| commentsCount | 9 |
| parentIssue | null |
| subIssues | [] |
| subIssuesCompleted | 0 |
| subIssuesTotal | 0 |
| blockedBy | [] |
| blocking | [] |
| closedAt | Apr 1, 2025, 10:03 PM |
Earthquakes tutorial still using model.Component instead of state.Provider

Here are my version numbers if it helps;
npm list | grep neo neo.mjs@8.35.1 /Users/gerard/Documents/neo/neotest/neolatest/neo ├── neo-jsdoc-x@1.0.5 ├── neo-jsdoc@1.0.1 FastImac:neo gerard$ node -v v23.10.0 FastImac:neo gerard$ npm -v 11.2.0

@camtnbikerrwc Ger, I hope I got all spots now. The commit on top of this comment is rather long. @maxrahder Max, it would be super nice, if you could double-check your guide once more.
Except for renaming view model to state provider, everything internally works the same way.
Some thoughts:
controller: {module: Controller},
stateProvider: {module: MainStateProvider},
While this syntax works fine, we could shorten it to:
controller: Controller,
stateProvider: MainStateProvider,
I also changed the class exports a bit. before:
Neo.setupClass(MainView);
export default MainView;
New:
export default Neo.setupClass(MainView);
The key difference is that the new version supports running different neo envs on one page (e.g. inside the Portal App we use the development mode for code inside code editors (can not get minified or bundled), and we use the dist/production env for everything else.

updated @maxrahder's createAppMinimal program too.

Hi Tobi, I need to head out for a few hours
Can u zip up the completed EarthQuakes example ( complete with google maps) and send to me.
Ger

Looks like this has been updated:
https://neomjs.com/dist/production/apps/portal/#/learn/tutorials.Earthquakes
I can start from fresh here and make sure it works.
Ger

you are making a valid point: i should drop the final version of the tutorial app into an own repository.
will do this today, probably only takes me 15m.

@camtnbikerrwc Ger, at the moment, i can not recommend the tutorial anymore: https://github.com/neomjs/earthquakes
even when dropping in @maxrahder's custom addon & wrapper, we get:
if i switch it to advanced markers, we get:
checked the docs, and it seems like you can now only use an API key, in case it is connected to a credit card.
in which case we can no longer provide a "generic" key.
so the message would be: "want to do this tutorial? give google your credit card details first."
not sure, if this is feasible.

i added a follow-up ticket: https://github.com/neomjs/neo/issues/6611
closing this one, since the original scope is resolved.

fwiw, I have had Googlemaps working with legacy and advanced markers, plus some other stuff, for a while now. It still works as of Neo 8.5.0 . However, no markers show at Neo 8.36.0 .
checking ... .
@maxrahder I will take a look into this one tomorrow!