In the redux-saga real-word example in store/configureStore.dev.js, a package named #redux-saga/simple-saga-monitor is included and added as saga middleware. Unfortunately I cannot find any information on what exactly this package does. Can someone shed some light on this?
I was wonder about the same and not much info has been shared online but looking at the source code here, it looks like a simple wrapper to log saga activities to the window or react native app console
Related
I'm trying to rewrite the Next.js official example with-react-intl in Typescript , but I'm having trouble with the HOC component PageWithIntl.js
My code is here https://github.com/soulmachine/with-react-intl.
Any ideas? Thanks!
Any pull requests is welcome.
I was trying the same thing by going through the Basics but got stuck on the "Fetching Data for Pages". There are too many typings missing for TS development.
I created some interfaces for page and component properties and I see that you have too. And the types under #types/next seem to be very lacking/incomplete.
Perhaps its time to write a comprehensive d.ts for next.js/ts?
I am game.
edit: just saw that your typeRoots point to src/#types instead of #types. Maybe nothing but still.
Now my code totally works, with only two minor flaws:
Line 50 of PageWithIntl.tsx, IntlProvider doesn't have the initialNow prop
Line 47 of PageWithIntl.tsx, Rest types may only be created from object types
The Aurelia is awesome, but it don't provide the solution for manage state.
I researching a bit and found the two concept of it.
Redux:
https://www.npmjs.com/package/redux-aurelia
It allow us use core concept of redux without extra sugar. In the minimal usable version may looks like that: https://gist.github.com/wegorich/5d1fabc550fb3f01e0a57d3d4308294a
It also more common for most of React apps.
Mobx: https://mobxjs.github.io/mobx/
It also looks good, and the core concept and syntax is more close to the Aurelia one. But I don't find anyone who use it with Aurelia :(
Question:
So the question is what the better way to manage state in the Aurelia application?
Maybe you should consider this article :
http://ilikekillnerds.com/2016/02/shared-state-in-aurelia/
It's appear that Aurelia ( and i m not aurelia dev ) manage singleton and reactive state easily. So, i suggest that : define Store and Reducers immediately without using Redux or MobX.
Maybe ImmutableJS can be very usefull here to define your store ( basically an object ).
And, do not forget, reducers are just pure functions. So, while you know how to write pure functions and you know how to apply to a store , you are fine.
there is an example blog post of using Redux with Aurelia found at sitepoint. https://www.sitepoint.com/managing-state-aurelia-with-redux/
Also there is an aurelia-redux plugin out there which is providing even more support: https://www.npmjs.com/package/aurelia-redux-plugin
I hope someone could give me a quick example how to configure the BTLE-Device correctly without the huge BLE-Manager library. Simply a litte GAP Authetication and one GATT-Service would be enough to start. I've managed to create my own GATT-Service and characteristics without the need for BLE-Manager but thanks to several defines, typedefs etc. I can't figure out how to do this for GAP and how to register my callbacks for it. Maybe someone has used these modules before and can give me a quick example how it's done?
Since you mentioned One GATT-Service with Authentication Atmel-BAS [Battery Service] example is easy one. To better understand you can download the getting started guide see the architecture. In-order to register the callbacks you need to check the order of callbacks in function ble_event_manager in ble_manager.c file.
I seek a little help to wrap a package for meteor. It has always been my weakness on this framework. I know it is not difficult, I read tutorials and some articles like :
https://www.discovermeteor.com/blog/wrapping-npm-packages/
http://www.meteorpedia.com/read/Packaging_existing_Libraries
However I get lost in export and stuff, and it is time to understand !
I tried to wrap this package :
https://github.com/fians/Waves
(I knew one day I was going to not find the package already made by someone on atmosphere :()
So I wanted to do the thnings right, following guidelines made by dandv. I forked the repo, add the meteor packages with the files : export.js and package.js. Following the example of moment As you can see here :
https://github.com/Voyag3r/Waves
Finally, in my app, I created the local package folder with the meteor command : meteor create --package voyag3r:waves I tried to called the waves variable, bit it is not defined. I tried with and without a capital letter. (like in the source code waves.js). No, I tried with this.Waves instead of just Waves in export.js, neither.
There is something I do not understand with namespace and visibility I think, and errors are not displaying useful information this time. Is there someone to explain to me ? Because I would like to do a lot of other packages !
Thanks !
Glad to see that you read through those documents above, as they're quite helpful. However, I understand that it can be confusing to work through the details. Hopefully, I can assist you.
I recently finished packaging up a couple of libraries for Meteor, so you should take a look at those repositories as examples:
jspdf:core
jspdf:autotable
More specifically, take a look at the jspdf:core repository above and inspect the meteor-pre.js and meteor-post.js files for how to handle exporting variables:
meteor-pre.js
var window = {};
meteor-post.js
jsPDF = window.jsPDF;
Other important files include package.js and package.json, and of course autopublish.json, for integrating version updates with http://autopublish.meteor.com/, a fantastic tool written by Luca Mussi #splendido.
Additionally, I would recommend that you review the Official Meteor integration directly from 3rd party libraries discussion and ask #splendido or #dandv for assistance with reserving the namespace for this library.
This process has gone through rapid change over the last few months, and although not perfect, it's improving steadily. I'm encouraged to see that, like me, you want to assist the Meteor ecosystem.
This is my first time using S#arp Architecture 2.0 in a project.
There is two folders in tasks project : Commands and CommandHandlers.
I shearch about it and tried to undestand by the cookbook project what do i have to put there. I am imagining that i have to do something like it was before: a "viewToModel" function and a SaveOrUpdate in the IRepository.
Somebody can explain the "Commands and CommandHandlers" or/and give me a good documentation about it?
Thanks a lot!
Have you seen the Cookbook wiki? Using commands?
From your questions, I understand you are after some sort of CRUD functionality, in which case going for a command and handler approach might be overkill, just load the entity in your controller, copy values from the form and save it. Using commands is more suited for a Task based UI and where there is some behavior you want on the entities.