workflow(sfc-playground): attach filename
This commit is contained in:
parent
ce5e0b67a9
commit
bb937e9033
@ -187,6 +187,7 @@ async function compileFile({ filename, code, compiled }: File) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (finalCode) {
|
if (finalCode) {
|
||||||
|
finalCode += `\n${COMP_IDENTIFIER}.__file = ${JSON.stringify(filename)}`
|
||||||
finalCode += `\nexport default ${COMP_IDENTIFIER}`
|
finalCode += `\nexport default ${COMP_IDENTIFIER}`
|
||||||
compiled.js = finalCode.trimStart()
|
compiled.js = finalCode.trimStart()
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user