WELCOME TO

LEARN WITH ARSHYAN

Confused about where to start? We’ve got you covered!

Browse our free tutorials and find the right course for you. Learn With Arshyan is my effort to share years of learning in a simple, practical way — so you can learn faster and smarter.

Tutorials

HTML Tutorial

The word hypertext markup language is composed of the words “hypertext” and “mar...

CSS Tutorial

CSS stands for Cascading Style Sheets. It describes how HTML elements are to be ...

JavaScript Tutorial

JavaScript is a lightweight, cross-platform, OOP language.

Things that make us proud

Choose your learning level

Beginner

With analytics tools, to help you share with current and future clients.

Advanced

All services for our team of industry experts, personal training.

Intermediate

Total collections, quoting, enrollment, and reporting in Italian and English.

Mastery

We can help you set up and manager your groups if you are become our partner.

Subscribe to Learn With Arshyan

Stay updated with new tutorials, tips, and free resources — delivered straight to your inbox!

Scroll to Top
Urls[url]=Date.now(),localStorage.setItem("prefetchedUrls",JSON.stringify(prefetchedUrls))}catch(e){console.warn("Failed to store prefetched URL in localStorage",e)}}cleanupPrefetchLinks(){try{const prefetchedUrls=JSON.parse(localStorage.getItem("prefetchedUrls")||"{}"),now=Date.now();let changed=!1;document.querySelectorAll('link[rel="prefetch"]').forEach(link=>{const url=link.href,timestamp=prefetchedUrls[url];(!timestamp||now-timestamp>this.config.prefetchTimeout)&&(link.remove(),delete prefetchedUrls[url],this.prefetched.delete(url),changed=!0)}),changed&&localStorage.setItem("prefetchedUrls",JSON.stringify(prefetchedUrls))}catch(e){console.warn("Failed to clean up prefetch links",e)}setTimeout(()=>this.cleanupPrefetchLinks(),36e5)}}class Prefetcher{static{__name(this,"Prefetcher")}constructor(config){this.config=config,this.queue=[],this.isProcessing=!1,this.lastPrefetchTime=0}prefetchUrl(url){this.queue.push(url),this.processQueue()}processQueue(){if(this.isProcessing)return;this.isProcessing=!0;const interval=setInterval(()=>{if(this.queue.length===0){clearInterval(interval),this.isProcessing=!1;return}const now=Date.now(),elapsed=now-this.lastPrefetchTime;this.queue.splice(0,Math.min(this.config.maxRPS,this.queue.length)).forEach(url=>{this.addPrefetchLink(url)}),this.lastPrefetchTime=now,this.queue.length===0&&(clearInterval(interval),this.isProcessing=!1)},1e3/this.config.maxRPS)}addPrefetchLink(url){if(document.querySelector(`link[rel="prefetch"][href="${url}"]`))return;const linkElement=document.createElement("link");linkElement.rel="prefetch",linkElement.href=url,linkElement.as="document",document.head.appendChild(linkElement),window.linkMonitor&&window.linkMonitor.markAsPrefetched(url)}}function init(){if(!shouldPrefetch()){console.log("Prefetching not supported or feasible on this device/connection.");return}const config=getConfig(),prefetcher=new Prefetcher(config),monitor=new LinkMonitor(config,url=>{prefetcher.prefetchUrl(url)});window.linkMonitor=monitor,monitor.startMonitoring();try{const prefetchedUrls=JSON.parse(localStorage.getItem("prefetchedUrls")||"{}");Object.keys(prefetchedUrls).forEach(url=>{monitor.prefetched.add(url)})}catch(e){console.warn("Failed to load prefetched URLs from localStorage",e)}}__name(init,"init");function eventHandler(){BV_PRELOAD_LINKS_EVENTS.forEach(eventType=>{document.removeEventListener(eventType,eventHandler)}),init()}__name(eventHandler,"eventHandler"),BV_PRELOAD_LINKS_EVENTS.forEach(eventType=>{document.addEventListener(eventType,eventHandler,{once:!0})});