Skip to content

Commit

Permalink
feat: info about next cache
Browse files Browse the repository at this point in the history
  • Loading branch information
patrykomiotek committed Feb 4, 2024
1 parent 4de2dba commit b96240c
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions apps/jobboard/src/services/offers.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import { JobOffer } from '@prisma/client';
import db from '@jobboard/prisma-client';
import { unstable_noStore as noStore } from 'next/cache';

export const fetchJobOffers = async (query: string | null) => {
const whereQuery = query
Expand Down Expand Up @@ -33,5 +34,6 @@ const wait = async (ms: number) =>

export const fetchOffersCount = async () => {
await wait(5000);
// noStore(); -- omit data store
return db.jobOffer.count();
};

0 comments on commit b96240c

Please sign in to comment.