# @johntravelertick/nguniversal-common

> Angular Universal common

Latest version **5.0.0-beta.5-john5** (published 2017-11-12) · MIT license · 0 weekly downloads

## Install

```sh
npm install @johntravelertick/nguniversal-common
pnpm add @johntravelertick/nguniversal-common
yarn add @johntravelertick/nguniversal-common
bun add @johntravelertick/nguniversal-common
```

## Health

**Score 20/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities.

Warnings: low downloads; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 5.0.0-beta.5-john5 |
| Published | 2017-11-12 |
| First published | 2017-11-09 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Node | >= 6.9.0 |
| Dependencies | 0 |
| Known vulnerabilities | 0 |
| Install scripts | no |
| GitHub stars | 3990 |
| Maintainers | johntravelertick |

## Links

- npm: https://www.npmjs.com/package/@johntravelertick/nguniversal-common
- Repository: https://github.com/angular/universal
- Issues: https://github.com/angular/universal/issues
- npm.io page: https://npm.io/package/@johntravelertick/nguniversal-common

## Recent versions

- 5.0.0-beta.5-john5 (latest) — 2017-11-12
- 5.0.0-beta.5-john4 — 2017-11-12
- 5.0.0-beta.5-john2 — 2017-11-12
- 5.0.0-beta.5 — 2017-11-09

## README

# Angular Universal Common Module

This is the common Angular Universal module that is common across server-side rendering app
irrespective of the rendering engine.

The package can be installed using:

`npm install @nguniversal/common --save`

## TransferHttpCacheModule

`TransferHttpCacheModule` installs a Http interceptor that avoids duplicate `HttpClient` requests
on the client, for requests that were already made when the application was rendered on the server
side.

When the module is installed in the application `NgModule`, it will intercept `HttpClient` requests
on the server and store the response in the `TransferState` key-value store. This is transferred to the client, which then uses it to respond to the same `HttpClient` requests on the client.

### Usage

To use the `TransferHttpCacheModule` just install it as part of the top-level App module.

That's it!

```ts
import {TransferHttpCacheModule} from '@nguniversal/common';

@NgModule({
  imports: [
    BrowserModule.withServerTransition({appId: 'my-app'}),
    TransferHttpCacheModule,
  ],
  bootstrap: [MyApp]
})
export class AppBrowserModule() {}
```

---
_Source: https://npm.io/package/@johntravelertick/nguniversal-common · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
