12 lines
342 B
TypeScript
12 lines
342 B
TypeScript
export default defineContentScript({
|
|
// Site that uses HTML5 history
|
|
matches: ['*://*.crunchyroll.com/*'],
|
|
|
|
main(ctx) {
|
|
ctx.addEventListener(window, 'wxt:locationchange', ({ newUrl, oldUrl }) => {
|
|
console.log('Location changed:', newUrl.href, oldUrl.href);
|
|
});
|
|
console.log('Watching for location change...');
|
|
},
|
|
});
|