Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(request): add request provider for SSR without adding express as… #206

Closed

Conversation

valorkin
Copy link

… a dep to a client lib

@pavankjadda pavankjadda self-requested a review January 13, 2022 03:34
@pavankjadda
Copy link
Collaborator

@valorkin thanks for the PR. Would you mind explaining the process you followed i.e. what does new package express-ssr do and instructions to test this PR

@@ -14,7 +15,8 @@ export class CookieService {
constructor(
@Inject(DOCUMENT) private document: Document,
// Get the `PLATFORM_ID` so we can check if we're in a browser.
@Inject(PLATFORM_ID) private platformId
@Inject(PLATFORM_ID) private platformId: any,
@Optional() @Inject(REQUEST_PROVIDER_TOKEN) private request: RequestProvider
Copy link
Collaborator

@pavankjadda pavankjadda Jan 13, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@valorkin I see you created Injection Token and supplied it here. Does it work for CSR along with SSR application? Would you mind creating a sample repo so that we can test this.

@stevermeister take a look at this

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, now playing with it here - https://github.com/stevermeister/ssr-coookie

return request;
};

export const expressRequestProvider: StaticProvider = {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be honest I have very little knowledge on this. I will read more about this

@valorkin
Copy link
Author

@pavankjadda you can discuss it with @stevermeister

@pavankjadda pavankjadda mentioned this pull request Apr 27, 2022
@pavankjadda
Copy link
Collaborator

Closes in favor of #237

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants