Skip to content

Commit

Permalink
feat: support collection in SSR
Browse files Browse the repository at this point in the history
chore: update dependencies
  • Loading branch information
zensh committed Dec 2, 2023
1 parent 3201687 commit b9f0e63
Show file tree
Hide file tree
Showing 10 changed files with 1,275 additions and 780 deletions.
6 changes: 3 additions & 3 deletions dist/api.js
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ export async function scrapingAPI(ctx) {
if (doc.isFresh) {
// a fresh document is a document that has been scraped within the last 3600 seconds
ctx.body = {
retry: 0,
retry: 0, // client can get the document after 0 seconds
result: doc.toJSON(),
};
return;
Expand All @@ -64,7 +64,7 @@ export async function scrapingAPI(ctx) {
if (!acquired) {
// fail to get the document scraping lock, it's being scraped by another process
ctx.body = {
retry: 1,
retry: 1, // client can get the document after 0 seconds
result: {
id: doc.row.id,
url: doc.row.url,
Expand Down Expand Up @@ -102,7 +102,7 @@ export async function scrapingAPI(ctx) {
logError(err);
});
ctx.body = {
retry: 2,
retry: 2, // client can get the document after 2 seconds
result: {
id: doc.row.id,
url: doc.row.url,
Expand Down
14 changes: 7 additions & 7 deletions dist/lang.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ export function lang639_3(lang) {
return '';
}
const rtlLanguageCodeList3 = [
'ara',
'heb',
'fas',
'urd',
'kas',
'pus',
'uig',
'ara', // Arabic
'heb', // Hebrew
'fas', // Persian
'urd', // Urdu
'kas', // Kashmiri
'pus', // Pashto
'uig', // Uighur
'snd', // Sindhi
];
export function isRTL(languageCode) {
Expand Down
Loading

0 comments on commit b9f0e63

Please sign in to comment.