Rearrange JSON files

pull/3326/head
Kamran Ahmed 2 years ago
parent 89a436a5b7
commit 8f8e2f41d8
  1. 9
      bin/compress-jsons.cjs
  2. 2
      bin/roadmap-content.cjs
  3. 1
      public/jsons/checklists/frontend-performance.json
  4. 0
      public/jsons/roadmaps/android.json
  5. 0
      public/jsons/roadmaps/angular.json
  6. 0
      public/jsons/roadmaps/aspnet-core.json
  7. 0
      public/jsons/roadmaps/backend.json
  8. 0
      public/jsons/roadmaps/blockchain.json
  9. 0
      public/jsons/roadmaps/computer-science.json
  10. 0
      public/jsons/roadmaps/design-system.json
  11. 0
      public/jsons/roadmaps/devops.json
  12. 0
      public/jsons/roadmaps/flutter.json
  13. 0
      public/jsons/roadmaps/frontend.json
  14. 0
      public/jsons/roadmaps/golang.json
  15. 0
      public/jsons/roadmaps/graphql.json
  16. 0
      public/jsons/roadmaps/java.json
  17. 0
      public/jsons/roadmaps/javascript.json
  18. 0
      public/jsons/roadmaps/nodejs.json
  19. 0
      public/jsons/roadmaps/python.json
  20. 0
      public/jsons/roadmaps/qa.json
  21. 0
      public/jsons/roadmaps/react.json
  22. 0
      public/jsons/roadmaps/software-architect.json
  23. 0
      public/jsons/roadmaps/software-design-architecture.json
  24. 0
      public/jsons/roadmaps/spring-boot.json
  25. 0
      public/jsons/roadmaps/system-design.json
  26. 0
      public/jsons/roadmaps/vue.json
  27. 2
      src/roadmaps/android/android.md
  28. 2
      src/roadmaps/angular/angular.md
  29. 2
      src/roadmaps/aspnet-core/aspnet-core.md
  30. 2
      src/roadmaps/backend/backend.md
  31. 2
      src/roadmaps/blockchain/blockchain.md
  32. 2
      src/roadmaps/computer-science/computer-science.md
  33. 2
      src/roadmaps/design-system/design-system.md
  34. 2
      src/roadmaps/devops/devops.md
  35. 2
      src/roadmaps/flutter/flutter.md
  36. 2
      src/roadmaps/frontend/frontend.md
  37. 2
      src/roadmaps/golang/golang.md
  38. 2
      src/roadmaps/graphql/graphql.md
  39. 2
      src/roadmaps/java/java.md
  40. 2
      src/roadmaps/javascript/javascript.md
  41. 2
      src/roadmaps/nodejs/nodejs.md
  42. 2
      src/roadmaps/python/python.md
  43. 2
      src/roadmaps/qa/qa.md
  44. 2
      src/roadmaps/react/react.md
  45. 2
      src/roadmaps/software-architect/software-architect.md
  46. 2
      src/roadmaps/software-design-architecture/software-design-architecture.md
  47. 2
      src/roadmaps/spring-boot/spring-boot.md
  48. 2
      src/roadmaps/system-design/system-design.md
  49. 2
      src/roadmaps/vue/vue.md
  50. BIN
      tests/guides.spec.ts-snapshots/guides-1-chromium-darwin.png
  51. BIN
      tests/index.spec.ts-snapshots/homepage-test-1-chromium-darwin.png
  52. BIN
      tests/index.spec.ts-snapshots/homepage-test-1-firefox-darwin.png
  53. BIN
      tests/index.spec.ts-snapshots/homepage-test-1-webkit-darwin.png
  54. BIN
      tests/roadmap.spec.ts-snapshots/roadmap-design-system-1-chromium-darwin.png
  55. BIN
      tests/roadmap.spec.ts-snapshots/roadmap-frontend-1-chromium-darwin.png
  56. BIN
      tests/roadmap.spec.ts-snapshots/roadmap-java-1-chromium-darwin.png
  57. BIN
      tests/roadmap.spec.ts-snapshots/roadmap-qa-1-chromium-darwin.png
  58. BIN
      tests/roadmap.spec.ts-snapshots/roadmap-react-1-chromium-darwin.png
  59. BIN
      tests/roadmap.spec.ts-snapshots/roadmap-system-design-1-chromium-darwin.png
  60. BIN
      tests/roadmap.spec.ts-snapshots/roadmaps-1-chromium-darwin.png
  61. BIN
      tests/videos.spec.ts-snapshots/videos-1-chromium-darwin.png

@ -2,13 +2,18 @@ const fs = require('node:fs');
const path = require('node:path');
const jsonsDir = path.join(process.cwd(), 'public/jsons');
const jsonFiles = fs.readdirSync(jsonsDir);
const childJsonDirs = fs.readdirSync(jsonsDir);
childJsonDirs.forEach((childJsonDir) => {
const fullChildJsonDirPath = path.join(jsonsDir, childJsonDir);
const jsonFiles = fs.readdirSync(fullChildJsonDirPath);
jsonFiles.forEach((jsonFileName) => {
console.log(`Compressing ${jsonFileName}...`);
const jsonFilePath = path.join(jsonsDir, jsonFileName);
const jsonFilePath = path.join(fullChildJsonDirPath, jsonFileName);
const json = require(jsonFilePath);
fs.writeFileSync(jsonFilePath, JSON.stringify(json));
});
});

@ -82,7 +82,7 @@ function prepareDirTree(control, dirTree, dirSortOrders) {
return { dirTree, dirSortOrders };
}
const roadmap = require(path.join(__dirname, `../public/jsons/${roadmapId}`));
const roadmap = require(path.join(__dirname, `../public/jsons/roadmaps/${roadmapId}`));
const controls = roadmap.mockup.controls.control;
// Prepare the dir tree that we will be creating and also calculate the sort orders

File diff suppressed because one or more lines are too long

@ -1,5 +1,5 @@
---
# jsonUrl: "/jsons/android.json"
# jsonUrl: "/jsons/roadmaps/android.json"
pdfUrl: "/pdfs/android.pdf"
order: 4
featuredTitle: "Android"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/angular.json"
jsonUrl: "/jsons/roadmaps/angular.json"
pdfUrl: "/pdfs/angular.pdf"
order: 3
featuredTitle: "Angular"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/aspnet-core.json"
jsonUrl: "/jsons/roadmaps/aspnet-core.json"
pdfUrl: "/pdfs/aspnet-core.pdf"
order: 9
featuredTitle: "ASP.NET Core"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/backend.json"
jsonUrl: "/jsons/roadmaps/backend.json"
pdfUrl: "/pdfs/backend.pdf"
order: 2
featuredTitle: "Backend"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/blockchain.json"
jsonUrl: "/jsons/roadmaps/blockchain.json"
pdfUrl: "/pdfs/blockchain.pdf"
order: 6
featuredTitle: "Blockchain"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/computer-science.json"
jsonUrl: "/jsons/roadmaps/computer-science.json"
pdfUrl: "/pdfs/computer-science.pdf"
order: 1
featuredTitle: "Computer Science"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/design-system.json"
jsonUrl: "/jsons/roadmaps/design-system.json"
pdfUrl: "/pdfs/design-system.pdf"
order: 13
featuredTitle: "Design System"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/devops.json"
jsonUrl: "/jsons/roadmaps/devops.json"
pdfUrl: "/pdfs/devops.pdf"
order: 3
featuredTitle: "DevOps"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/flutter.json"
jsonUrl: "/jsons/roadmaps/flutter.json"
pdfUrl: "/pdfs/flutter.pdf"
order: 10
featuredTitle: "Flutter"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/frontend.json"
jsonUrl: "/jsons/roadmaps/frontend.json"
pdfUrl: "/pdfs/frontend.pdf"
order: 1
featuredTitle: "Frontend"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/golang.json"
jsonUrl: "/jsons/roadmaps/golang.json"
pdfUrl: "/pdfs/golang.pdf"
order: 8
featuredTitle: "Go"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/graphql.json"
jsonUrl: "/jsons/roadmaps/graphql.json"
pdfUrl: "/pdfs/graphql.pdf"
order: 12
featuredTitle: "GraphQL"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/java.json"
jsonUrl: "/jsons/roadmaps/java.json"
pdfUrl: "/pdfs/java.pdf"
order: 9
featuredTitle: "Java"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/javascript.json"
jsonUrl: "/jsons/roadmaps/javascript.json"
pdfUrl: "/pdfs/javascript.pdf"
order: 5
featuredTitle: "JavaScript"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/nodejs.json"
jsonUrl: "/jsons/roadmaps/nodejs.json"
pdfUrl: "/pdfs/nodejs.pdf"
order: 6
featuredTitle: "Node.js"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/python.json"
jsonUrl: "/jsons/roadmaps/python.json"
pdfUrl: "/pdfs/python.pdf"
order: 7
featuredTitle: "Python"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/qa.json"
jsonUrl: "/jsons/roadmaps/qa.json"
pdfUrl: "/pdfs/qa.pdf"
order: 7
featuredTitle: "QA"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/react.json"
jsonUrl: "/jsons/roadmaps/react.json"
pdfUrl: "/pdfs/react.pdf"
order: 2
featuredTitle: "React"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/software-architect.json"
jsonUrl: "/jsons/roadmaps/software-architect.json"
pdfUrl: "/pdfs/software-architect.pdf"
order: 8
featuredTitle: "Software Architect"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/software-design-architecture.json"
jsonUrl: "/jsons/roadmaps/software-design-architecture.json"
pdfUrl: "/pdfs/software-design-architecture.pdf"
order: 12
featuredTitle: "Design and Architecture"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/spring-boot.json"
jsonUrl: "/jsons/roadmaps/spring-boot.json"
pdfUrl: "/pdfs/spring-boot.pdf"
order: 10
featuredTitle: "Spring Boot"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/system-design.json"
jsonUrl: "/jsons/roadmaps/system-design.json"
pdfUrl: "/pdfs/system-design.pdf"
order: 11
featuredTitle: "System Design"

@ -1,5 +1,5 @@
---
jsonUrl: "/jsons/vue.json"
jsonUrl: "/jsons/roadmaps/vue.json"
pdfUrl: "/pdfs/vue.pdf"
order: 4
featuredTitle: "Vue"

Binary file not shown.

Before

Width:  |  Height:  |  Size: 262 KiB

After

Width:  |  Height:  |  Size: 269 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 346 KiB

After

Width:  |  Height:  |  Size: 352 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 359 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 563 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 555 KiB

After

Width:  |  Height:  |  Size: 555 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 800 KiB

After

Width:  |  Height:  |  Size: 801 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 344 KiB

After

Width:  |  Height:  |  Size: 344 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 538 KiB

After

Width:  |  Height:  |  Size: 538 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 369 KiB

After

Width:  |  Height:  |  Size: 369 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 640 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1006 KiB

After

Width:  |  Height:  |  Size: 1.0 MiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 331 KiB

After

Width:  |  Height:  |  Size: 331 KiB

Loading…
Cancel
Save