const fs = require('fs');
const content = fs.readFileSync('dist/assets/index-D9sWWWv_.js', 'utf8');

const targetIdx = 988452; // index of live-sales-report-container
const sub = content.substring(targetIdx - 18000, targetIdx);
const pos = sub.lastIndexOf('live-sales-report-container');

// Let's find "const" or "let" or variables list inside this 18KB chunk
let searchPos = sub.indexOf('const');
if (searchPos === -1) searchPos = sub.indexOf('let');
if (searchPos !== -1) {
  console.log('Found variable declaration relative pos:', searchPos);
  console.log(sub.substring(searchPos, searchPos + 1500));
} else {
  console.log('No const/let found. Let\'s print first 2000 chars of this 18KB chunk:');
  console.log(sub.substring(0, 2000));
}
