MCPcopy Create free account
hub / github.com/Kudo/react-native-v8 / createGeneratedHeaderComment

Function createGeneratedHeaderComment

plugin/src/generateCode.ts:128–137  ·  view source on GitHub ↗
(
  contents: string,
  tag: string,
  comment: string
)

Source from the content-addressed store, hash-verified

126}
127
128export function createGeneratedHeaderComment(
129 contents: string,
130 tag: string,
131 comment: string
132): string {
133 const hashKey = createHash(contents);
134
135 // Everything after the `${tag} ` is unversioned and can be freely modified without breaking changes.
136 return `${comment} @generated begin ${tag} - expo prebuild (DO NOT MODIFY) ${hashKey}`;
137}
138
139export function createHash(src: string): string {
140 // this doesn't need to be secure, the shorter the better.

Callers 1

mergeContentsFunction · 0.85

Calls 1

createHashFunction · 0.85

Tested by

no test coverage detected