Skip to content

Commit

Permalink
perf: removed redundant javascript code and unused packages
Browse files Browse the repository at this point in the history
  • Loading branch information
AtharvAgarwal20 committed Oct 14, 2024
1 parent e127e7d commit 6c28b93
Show file tree
Hide file tree
Showing 6 changed files with 3,851 additions and 11,836 deletions.
33 changes: 14 additions & 19 deletions components/Preloader/Preloader.tsx
Original file line number Diff line number Diff line change
@@ -1,22 +1,17 @@
import styles from "./preloader.module.scss";

function isSafari() {
const userAgent = navigator.userAgent.toLowerCase();
return userAgent.includes("safari") && !userAgent.includes("chrome");
}

export default function Preloader({ ...props }) {
return (
<div className={styles.preloader} {...props} id="preloader">
{/* <video
autoPlay
disablePictureInPicture
loop
muted
preload="auto"
src="/Videos/preloaderCoinVideo.mp4"
/> */}
<img src="/Videos/preloaderCoinVideo.gif" alt="preloader gif" />
</div>
);
export default function Preloader({...props}) {
return (
<div className={styles.preloader} {...props} id="preloader">
<video
autoPlay
disablePictureInPicture
loop
muted
preload="auto"
src="/Videos/preloaderCoinVideo.mp4"
/>
{/*<img src="/Videos/preloaderCoinVideo.gif" alt="preloader gif"/>*/}
</div>
);
}
14 changes: 7 additions & 7 deletions next.config.mjs
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
const nextConfig = {
webpack: (config, options) => {
config.module.rules.push({
test: /\.(glsl|vs|fs|vert|frag)$/,
use: ["raw-loader"],
});
webpack: (config) => {
config.module.rules.push({
test: /\.(glsl|vs|fs|vert|frag)$/,
// use: ["raw-loader"],
});

return config;
},
return config;
},
};

export default nextConfig;
Expand Down
Loading

0 comments on commit 6c28b93

Please sign in to comment.