-
Notifications
You must be signed in to change notification settings - Fork 100
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does not work with React #7
Comments
+1 |
Think this means we will have to fix this ourself :/ |
Just put the css files from cdn and everything should work. |
Any examples on how to get it working on React/Next.js |
To make kursor work with Gatsby just put the code below to gatsb-browser.js
|
Hi guys, I also had the same problem while using this dependency with Next.js. Read this from the documentation to get a better understanding: https://bit.ly/3rMUWQL "_document.jsx" code: import Document, { Html, Head, Main, NextScript } from 'next/document'
class MyDocument extends Document {
static async getInitialProps(ctx) {
const initialProps = await Document.getInitialProps(ctx)
return { ...initialProps }
}
render() {
return (
<Html lang="en">
<Head>
<link rel="stylesheet" href="https://unpkg.com/kursor/dist/kursor.css" />
</Head>
<body>
<Main />
<NextScript />
</body>
<script src="https://unpkg.com/kursor" />
<script dangerouslySetInnerHTML={{__html:`new kursor({ type: 1, removeDefaultCursor: true })`}} />
</Html>
)
}
}
export default MyDocument Hope this helps 😉 |
It's so easy to use like cutting a cake. #import you can change the type as you want.new Kursor({ |
my cursor only show on the hero section only not to all body by default it should be on body but not work |
Tried to implement this cursor in my react app but it wasn't compatible. Could this be fixed?
The text was updated successfully, but these errors were encountered: