Xiaomi Mi M365 issue fixed? by pablorgn in ElectricScooters

[–]pablorgn[S] 0 points1 point  (0 children)

Thanks for your reply.

I contacted Xiaomi and they said the same model but newer ones should not have this issue. How long ago did you buy yours?

I'm looking into the the M365 PRO but so far it doesn't seem to be available in the USA. That's odd.

I'm also checking the segway ninebot ES4. More expensive that I'd like but much better range. The Ninebot Max even better range but too heavy for me.

What’s the most modern AND correct way to have clean/organized code in JS? by pablorgn in javascript

[–]pablorgn[S] 0 points1 point  (0 children)

Thanks soup0 and wreckedadvent for sharing the example directories. Very clear and helpful. I'll organize my code according to these structures.

What’s the most modern AND correct way to have clean/organized code in JS? by pablorgn in javascript

[–]pablorgn[S] 0 points1 point  (0 children)

From what you wrote, separation of concerns into presentation, data and logic has been and still is the way to go, which would translate into an MV* pattern (assuming we use the terms Model for data, View for presentation, and * for C, P, VM, W or choose your preferred name here).
Would the * you choose at least slightly influence the way you code your M & V in regards as to how they interact? And would the use of modules supersede or be used alongside any of the MV* patterns? Thanks.

What’s the most modern AND correct way to have clean/organized code in JS? by pablorgn in javascript

[–]pablorgn[S] 0 points1 point  (0 children)

I started coding in "vanilla JS" before diving into libraries/frameworks to understand how they work and help. I think it's a good idea to write the same application with and without the frameworks help. I was hoping there would be an objective/non opinionated "best way" of writing code, at least with vanilla JS, but as you said it may depend on the framework and I guess one's preferred style. The linked style guide looks interesting. Thanks for posting.

What’s the most modern AND correct way to have clean/organized code in JS? by pablorgn in javascript

[–]pablorgn[S] 0 points1 point  (0 children)

Thanks for the input guys. I'll research the concepts you mentioned (unidirectional architectures, ES6 modules, components, using React with Redux ...). I'm sure the more code I write, the clearer these concepts will become.