5
0
Fork 0
mirror of https://0xacab.org/sutty/sutty synced 2024-11-23 00:46:23 +00:00
panel/app/javascript/packs/application.js

46 lines
1 KiB
JavaScript
Raw Normal View History

/* eslint no-console:0 */
import { Notifier } from '@airbrake/browser'
try {
window.airbrake = new Notifier({
projectId: window.env.AIRBRAKE_PROJECT_ID,
projectKey: window.env.AIRBRAKE_PROJECT_KEY,
host: window.env.PANEL_URL
});
const ignoredErrors = ["htmx:afterRequest", "htmx:sendAbort"];
console.originalError = console.error;
console.error = (...e) => {
const msg = e.join(" ");
if (!ignoredErrors.some(x => msg.includes(x))) {
window.airbrake.notify(e.join(" "));
}
return console.originalError(...e);
};
} catch(e) {
console.error(e);
}
2020-11-19 23:35:29 +00:00
import 'core-js/stable'
import 'regenerator-runtime/runtime'
2020-11-19 23:38:33 +00:00
import 'controllers'
import 'editor/editor'
2021-04-07 20:45:27 +00:00
import 'fork-awesome/scss/fork-awesome.scss'
import 'etc'
2021-04-07 20:45:27 +00:00
import Rails from '@rails/ujs'
import Turbolinks from 'turbolinks'
import * as ActiveStorage from '@rails/activestorage'
2021-10-08 19:31:02 +00:00
import 'chartkick/chart.js'
2020-06-28 00:42:15 +00:00
2021-04-07 20:45:27 +00:00
Rails.start()
Turbolinks.start()
ActiveStorage.start()
2024-06-04 20:07:05 +00:00
window.htmx = require("@suttyweb/htmx.org/dist/htmx.js");
window.htmx.config.selfRequestsOnly = true;