anyone who has integerated uniswap with next.js 14. I'm using that with next.js 14 and if i use "use client" directive i get the following error
./node_modules/brotli/build/encode.js:2:141
Module not found: Can't resolve 'fs'
if i don't use "use client" directive, i get the following error.
Error: createContext only works in Client Components. Add the "use client" directive at the top of the file to use it. Read more: https://nextjs.org/docs/messages/context-in-server-component
Any update on the swap widget. Here is my code for that
// 'use client';
import React from 'react';
import '@uniswap/widgets/fonts.css';
import { SwapWidget } from '@uniswap/widgets';
const Uniswap = () => {
return (
<div className="Uniswap">
<SwapWidget />
</div>
);
};
export default Uniswap;
I want the uniswap widget to be working