Research
Security News
Threat Actor Exposes Playbook for Exploiting npm to Build Blockchain-Powered Botnets
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
@ngrx/store-devtools
Advanced tools
@ngrx/store-devtools is a powerful tool for debugging and inspecting the state of your Angular applications using NgRx. It provides time-travel debugging, state inspection, and action logging, which can significantly enhance the development experience.
Time-Travel Debugging
Time-travel debugging allows you to go back and forth through the state changes in your application. This is useful for understanding how state evolves over time and for identifying where things might have gone wrong.
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
import { environment } from '../environments/environment';
@NgModule({
imports: [
StoreDevtoolsModule.instrument({
maxAge: 25, // Retains last 25 states
logOnly: environment.production, // Restrict extension to log-only mode
}),
],
})
export class AppModule {}
State Inspection
State inspection allows you to view the current state of your application at any point in time. This can be extremely helpful for debugging and understanding the state of your application.
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
@NgModule({
imports: [
StoreDevtoolsModule.instrument({
maxAge: 25,
logOnly: false,
}),
],
})
export class AppModule {}
Action Logging
Action logging provides a log of all the actions that have been dispatched in your application. This can help you understand the sequence of events that led to a particular state.
import { StoreDevtoolsModule } from '@ngrx/store-devtools';
@NgModule({
imports: [
StoreDevtoolsModule.instrument({
maxAge: 25,
logOnly: false,
}),
],
})
export class AppModule {}
Redux DevTools is a set of tools to help debug Redux applications. It offers similar functionalities to @ngrx/store-devtools, such as time-travel debugging, state inspection, and action logging. However, it is designed for use with Redux rather than NgRx.
MobX DevTools provides a set of tools for debugging MobX applications. It includes features like state inspection and action logging, similar to @ngrx/store-devtools, but is tailored for use with MobX.
Vue DevTools is a set of debugging tools for Vue.js applications. It offers state inspection, time-travel debugging, and action logging, similar to @ngrx/store-devtools, but is specifically designed for Vue.js.
Devtools for @ngrx/store.
npm install @ngrx/store-devtools --save
To instrument @ngrx/store and use the devtools, you will need to setup the instrumentation providers using instrumentStore()
:
import {StoreDevtoolsModule} from '@ngrx/store-devtools';
@NgModule({
imports: [
StoreModule.provideStore(rootReducer),
// Note that you must instrument after importing StoreModule
StoreDevtoolsModule.instrumentStore({
maxAge: 5,
monitor: monitorReducer
})
]
})
See @ngrx/store-log-monitor for an example monitor built for Angular 2
Please read contributing guidelines here.
14.0.0-beta.0 (2022-05-30)
LetDirective
is strongly typed when null
or
undefined
is passed as input.BEFORE:
<p *ngrxLet="null as n">{{ n }}</p>
<p *ngrxLet="undefined as u">{{ u }}</p>
n
is any
.u
is any
.AFTER:
<p *ngrxLet="null as n">{{ n }}</p>
<p *ngrxLet="undefined as u">{{ u }}</p>
n
is null
.u
is undefined
.Creating actions, reducers, and effects is possible without using the creator syntax is possible.
AFTER:
--creators
(and -c
) is removed from the schematic options.skipTests
option is removed while generating actions.BEFORE:
Minimum version of Angular was 13.x
AFTER:
Minimum version of Angular is 14.x
BEFORE:
The change detection is triggered via changeDetectorRef.detectChanges
in zone-less mode.
AFTER:
The change detection is triggered via ɵmarkDirty
in zone-less mode.
$error
property from LetDirective
's view context is
a thrown error or undefined
instead of true
/false
.BEFORE:
<p *ngrxLet="obs$; $error as e">{{ e }}</p>
e
will be true
when obs$
emits error event.e
will be false
when obs$
emits next/complete event.AFTER:
<p *ngrxLet="obs$; $error as e">{{ e }}</p>
e
will be thrown error when obs$
emits error event.e
will be undefined
when obs$
emits next/complete event.<a name="13.1.0"></a>
FAQs
Developer tools for @ngrx/store
The npm package @ngrx/store-devtools receives a total of 342,330 weekly downloads. As such, @ngrx/store-devtools popularity was classified as popular.
We found that @ngrx/store-devtools demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 4 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
A threat actor's playbook for exploiting the npm ecosystem was exposed on the dark web, detailing how to build a blockchain-powered botnet.
Security News
NVD’s backlog surpasses 20,000 CVEs as analysis slows and NIST announces new system updates to address ongoing delays.
Security News
Research
A malicious npm package disguised as a WhatsApp client is exploiting authentication flows with a remote kill switch to exfiltrate data and destroy files.