@hyperframes/lint 0.8.224 → 0.8.226

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.
Files changed (2) hide show
  1. package/dist/index.js +6 -5
  2. package/package.json +2 -2
package/dist/index.js CHANGED
@@ -7130,7 +7130,7 @@ function shouldBlockRender(strictErrors, strictAll, totalErrors, totalWarnings)
7130
7130
 
7131
7131
  // src/project.ts
7132
7132
  import { createHash } from "crypto";
7133
- import { existsSync as existsSync2, readFileSync, readdirSync } from "fs";
7133
+ import { existsSync as existsSync2, readdirSync } from "fs";
7134
7134
  import { dirname as dirname2, extname, join as join3, relative as relative2, resolve } from "path";
7135
7135
  import { rewriteAssetPath as rewriteAssetPath2 } from "@hyperframes/parsers/asset-paths";
7136
7136
  import { spansOverlap } from "@hyperframes/parsers/time-spans";
@@ -7158,7 +7158,8 @@ import {
7158
7158
  readProjectFile as readProjectFile2,
7159
7159
  resolveExistingLocalAsset as resolveExistingLocalAsset3,
7160
7160
  resolveLocalAssetCandidates,
7161
- resolveProjectRelativeSrc
7161
+ resolveProjectRelativeSrc,
7162
+ readTextFile
7162
7163
  } from "@hyperframes/parsers/asset-resolution";
7163
7164
  import { encodeUrlPath } from "@hyperframes/parsers";
7164
7165
 
@@ -7609,7 +7610,7 @@ async function lintProject(projectDir, entryFile, hostOptions = {}) {
7609
7610
  let totalErrors = 0;
7610
7611
  let totalWarnings = 0;
7611
7612
  let totalInfos = 0;
7612
- const rootHtml = readFileSync(indexPath, "utf-8");
7613
+ const rootHtml = readTextFile(indexPath);
7613
7614
  const projectFontFamilies = declaredProjectFontFamilies(
7614
7615
  projectDir,
7615
7616
  mountedSources(projectDir, rootHtml, rootCompSrcPath)
@@ -7645,7 +7646,7 @@ async function lintProject(projectDir, entryFile, hostOptions = {}) {
7645
7646
  const files = collectHtmlFiles(compositionsDir, "").sort();
7646
7647
  for (const file of files) {
7647
7648
  const filePath = join3(compositionsDir, file);
7648
- const html = readFileSync(filePath, "utf-8");
7649
+ const html = readTextFile(filePath);
7649
7650
  const compSrcPath = `compositions/${file}`;
7650
7651
  allHtmlSources.push({ html, compSrcPath });
7651
7652
  if (isSnippetFragment(html)) continue;
@@ -7949,7 +7950,7 @@ function lintMultipleRootCompositions(projectDir) {
7949
7950
  const rootCompositions = [];
7950
7951
  for (const file of rootHtmlFiles) {
7951
7952
  if (PAGES_OPENED_BESIDE_INDEX.has(file)) continue;
7952
- const content = readFileSync(join3(projectDir, file), "utf-8");
7953
+ const content = readTextFile(join3(projectDir, file));
7953
7954
  if (/data-composition-id/i.test(content)) {
7954
7955
  rootCompositions.push(file);
7955
7956
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hyperframes/lint",
3
- "version": "0.8.224",
3
+ "version": "0.8.226",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/heygen-com/hyperframes",
@@ -35,7 +35,7 @@
35
35
  "linkedom": "^0.18.12",
36
36
  "postcss": "^8.5.8",
37
37
  "postcss-selector-parser": "^7.1.4",
38
- "@hyperframes/parsers": "0.8.224"
38
+ "@hyperframes/parsers": "0.8.226"
39
39
  },
40
40
  "devDependencies": {
41
41
  "@types/node": "^25.0.10",