@socialgouv/fiches-travail-data-types 4.431.0 → 4.433.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,2 +1,2 @@
1
- export function fetchFeed(url: any): Promise<any>;
1
+ export function fetchFeed(url: any): Promise<any[]>;
2
2
  export function scrap(urls: any): Promise<any[]>;
@@ -21,7 +21,9 @@ async function fetchFeed(url) {
21
21
  retry: 3,
22
22
  });
23
23
  const { fiches: feed } = JSON.parse(response.body);
24
- return feed;
24
+ const localJson = fs_1.default.readFileSync(path_1.default.join(__dirname, "../../local.data.json"), "utf8");
25
+ const { fiches: localFeed } = JSON.parse(localJson);
26
+ return [...feed, ...localFeed];
25
27
  }
26
28
  exports.fetchFeed = fetchFeed;
27
29
  async function scrap(urls) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@socialgouv/fiches-travail-data-types",
3
- "version": "4.431.0",
3
+ "version": "4.433.0",
4
4
  "main": "build/index.js",
5
5
  "module": "build/index.js",
6
6
  "files": [