So I use angular services declared as public to keep the state of what the service controls between differents views in the service's variables.
Example: View 1 to scan and connect to bluetooth devices. View 2 (view 1 already destroyed): Show device information of bluetooth device connected(in view 1).
Im just starting with NextJS and I don't see any way in the documentation to import components like public service in angular.
I do have been researching and only things similar are ContextAPI and redux, to save maybe the components variables states like that. But it isn't quite like Angular services. Is there something like angular public services or I have to use manually contextapi/redux to save the information between components