![pnpm 10.0.0 Blocks Lifecycle Scripts by Default](https://cdn.sanity.io/images/cgdhsj6q/production/387e09b040c564e324704dac66871c6456fe5ded-1024x1024.png?w=400&fit=max&auto=format)
Security News
pnpm 10.0.0 Blocks Lifecycle Scripts by Default
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
@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.
The sources for this package are in the main NgRx repo. Please file issues and pull requests against that repo.
License: MIT
19.0.0-rc.0 (2024-12-10)
signalMethod
(#4597) (bdd1d3e), closes #4581withProps
base feature (#4607) (e626082)withProps
(#4612) (5f803d0), closes #4608computed
property in SignalStoreFeatureResult
type is renamed to props
.EntityComputed
and NamedEntityComputed
types in the entities
plugin are renamed to EntityProps
and NamedEntityProps
.BEFORE:
import { computed, Signal } from '@angular/core';
import { signalStoreFeature, SignalStoreFeature, type, withComputed } from '@ngrx/signals';
import { EntityComputed } from '@ngrx/signals/entities';
export function withTotalEntities<Entity>(): SignalStoreFeature<{ state: {}; computed: EntityComputed<Entity>; methods: {} }, { state: {}; computed: { total: Signal<number> }; methods: {} }> {
return signalStoreFeature(
{ computed: type<EntityComputed<Entity>>() },
withComputed(({ entities }) => ({
total: computed(() => entities().length),
}))
);
}
AFTER:
import { computed, Signal } from '@angular/core';
import { signalStoreFeature, SignalStoreFeature, type, withComputed } from '@ngrx/signals';
import { EntityProps } from '@ngrx/signals/entities';
export function withTotalEntities<Entity>(): SignalStoreFeature<{ state: {}; props: EntityProps<Entity>; methods: {} }, { state: {}; props: { total: Signal<number> }; methods: {} }> {
return signalStoreFeature(
{ props: type<EntityProps<Entity>>() },
withComputed(({ entities }) => ({
total: computed(() => entities().length),
}))
);
}
<a name="19.0.0-beta.0""></a>
FAQs
Developer tools for @ngrx/store
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.
Security News
pnpm 10 blocks lifecycle scripts by default to improve security, addressing supply chain attack risks but sparking debate over compatibility and workflow changes.
Product
Socket now supports uv.lock files to ensure consistent, secure dependency resolution for Python projects and enhance supply chain security.
Research
Security News
Socket researchers have discovered multiple malicious npm packages targeting Solana private keys, abusing Gmail to exfiltrate the data and drain Solana wallets.