🚀 Quick Start (30 seconds)

Browser Console

What you'll do: Load the library and scrape the current page for headings and paragraphs.

Copy & Paste to Console
(async()=>{if(window.tOnline&&window.tOnline.init) return window.tOnline;const url='https://lib.mediawrite.cloud/tOnline.js';const txt=await fetch(url).then(r=>r.text());(new Function(txt))();let i=0;while(!(window.tOnline&&window.tOnline.init)&&i<50){await new Promise(r=>setTimeout(r,100));i++;}if(!(window.tOnline&&window.tOnline.init))throw new Error('tOnline load failed');const r=await window.tOnline.init('init','my-page',1,window.location.href,{rules:[{selector:'h1,p',atomize:'block'}]}, {}, document);console.log(r.tContents)})();

Node.js / Puppeteer

Node.js Setup
const tOnline=require('./tOnline.js');const html='<h1>My Page</h1><p>Content here</p>';(async()=>{const r=await tOnline.init('init','my-job-id',1,'https://example.com',{rules:[{selector:'h1,p',atomize:'block'}]}, {}, html);console.log(r.tContents)})();
✓ Ready! Your library is now active and ready to scrape.

🎯 Live Demo

Try scraping this HTML sample in real-time:

Sample HTML:

The Future of AI

Artificial Intelligence is evolving rapidly.

Machine learning models are becoming more powerful.

Read more...

Scraping Rules:

{ "tO_ID": "demo-page", "rules": [ { "name": "Headings", "selector": "h1", "atomize": "block" }, { "name": "Paragraphs", "selector": "p", "atomize": "block" } ] }

Output:

Click "Run Demo" to see extracted content...