Update npm packages to latest versions
Fix JavaScript sourcemap paths to show full file locations Implement --build-debug flag and complete Build UI streaming Add xterm.js terminal UI and fix asset path routing Add RSpade Build UI service with WebSocket support 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
#!/usr/bin/env node
|
||||
|
||||
const fs = require('fs');
|
||||
const path = require('path');
|
||||
const crypto = require('crypto');
|
||||
const babel = require('@babel/core');
|
||||
|
||||
@@ -214,8 +215,12 @@ const prefixGeneratedVariables = function() {
|
||||
|
||||
try {
|
||||
// Configure Babel transformation
|
||||
// Use relative path for sourcemap to match SCSS behavior
|
||||
const relativeFilePath = path.relative(process.cwd(), filePath);
|
||||
|
||||
const result = babel.transformSync(content, {
|
||||
filename: filePath,
|
||||
filename: relativeFilePath,
|
||||
sourceFileName: relativeFilePath, // Explicitly set source filename for sourcemap
|
||||
sourceMaps: 'inline',
|
||||
presets: [
|
||||
['@babel/preset-env', targetPresets[target] || targetPresets.modern]
|
||||
|
||||
Reference in New Issue
Block a user