hosso / notion-custom-domain Goto Github PK
View Code? Open in Web Editor NEWCustom domains for your Notion pages
Home Page: https://notion-custom-domain.hosso.co
License: MIT License
Custom domains for your Notion pages
Home Page: https://notion-custom-domain.hosso.co
License: MIT License
In vercel I created an environment variables.The name is PAGE_URL, value is https://1kuxyz.notion.site/1-xyz-s-Shop-ef43d1756d1c4d7cb49c8bc96dec3b13.
And add custom domain is vercel.1ku.xyz.
After deploy, visit the custom domain site, the url will auto changed to http:/vercel.1ku.xyz/1kuxyz in address bar.
It auto add a suffix '1kuxyz' in url.
I think this suffix should be extra one.
Hello,
This is not an issue, this is a question.
Is it possible to use this proxy for Framer sites too? So I wouldn't have to pay for a plan on Framer. Is it also possible to remove the Framer watermark using the proxy, similar to how you remove the Notion Logo for notion sites?
Thanks
I wish there was a feature to remove the 'Try Notion' brand in the top corner of the website so that the website looks cleaner.
I deployed about four months ago and has been working normally.
But yesterday, I discovered that the following error occurred during the visit:
I tried to add window. CONFIG. domainBaseUrl="xxx. com"
to the index.ts
.
Although it can be accessed, it is currently unable to access the homepage and requires login, which may result in errors
https://easonyang.com/posts/build-a-website-with-notion/#%E8%87%AA%E5%8A%A9%E5%8F%8D%E5%90%91%E4%BB%A3%E7%90%86%E5%BB%BA%E7%AB%99
I also attempted to modify some domain in the response based on this, but it caused the Notion front-end code to judge requestedOnPublicDomain as true and carry this parameter to request whether login is required from the Notion backend, ultimately leading to a strong jump to the login page
Hello,
I'm testing the new fix on the custom domain, the custom domain issue is fixed, awesome!
But the notion file download link seems not working, maybe it's the same domain issue, the original file points to https://file.notion.so/xxxx
could you please help to take a look at it? thanks!
Is there a way to not use to meta titel and description from notion but make your own?
Thank you for your great work, this proxy is wonderful. When I deployed this, however, it didn't work. The page redirected to https://[my-project-name].notion.site. The demo page seems also to redirect to notion.site. Something on Notion side has changed, maybe.
Only the title appears correctly. The rest of the page is blank.
What I did:
Imported the forked repo in Vercel
Created the env variable Page_URL
and added the public notion page URL = https://silver-push-150.notion.site/Getting-Started-86b84286e165406487e88b3e30103b71
Deployed.
When open https://notion-custom-domain.hosso.co by safari/chrome/edge on iOS.
You will see blank page.
Is there any way to customize the Open Graph data (metadata)? I would like to set them up myself before the fetching starts, like static variables.
I found a lot of services that can customize notion webpage and I found this repo to let me know how to achieve it, It's so great. But my cover image didn't show up. and I want to know how to know a lot of proxy knowledge. I found a lot of difficult code in index.ts. I just know add some style tag to hide topbar haha.
Hi.
I've been trying your code and there is a problem (at least for me). Maybe you can give me some tips about it.
PNG images are not really showing up. SVG's are. I can't figure it out.
@ShiinaRinne @hosso
Since we can't reopen #17 here is a new issue. Please refer to the final discussion over there for more context.
It seems that Notion has written some things in a new mainApp-*.js.
We tried to apply the rules of app-*.js, but did not get the expected results.
I deploy notion-custom-domain by vercel,but it doesn't work.
I wonder, maybe because of notion public page link changed.
Before:
notion.so/abc/xxxxx12345
Now:
abc.notion.site/xxxxx12345
Hi there, I want redirect the browser to load a different page which is not a notion page (say https://google.com) when the user types in the path /extra
(e.g. https://notion-custom-domain.hosso.co/extra)
I was trying to add this before the app.use(proxy) portion (i.e. on line 58), but it gets ignored and just reloads homepage:
app.get('/extra', (req, res) => {
res.redirect('https://google.com')
})
it seems like a simple problem. anyone able to help?
The URL works on both desktop and inkognito mobile, but not "normal" on mobile.
Example URL: is310.vercel.app
I believe there is an error handling databases as the home/entry page. I get a blank page along with the following error: Uncaught SyntaxError: Invalid regular expression flags (at app-dfa330d436d18bd4f80e.js:1:301)
I think this is because of the page id matching regex on line 11. Here is what pagePath when doing a page vs database:
Page PAGE_URL: https://stealthisnonprofit.notion.site/STEAL-THIS-NONPROFIT-5b1f8b9e98fb433095582219cbbe6462
pagePath: 5b1f8b9e98fb433095582219cbbe6462
Database PAGE_URL: https://stealthisnonprofit.notion.site/214726270a4a44d48d0d33f2ce4a062c
pagePath: /214726270a4a44d48d0d33f2ce4a062c
The match function seems to expect a "-". I fixed this by simply replacing the leading slash with an empty string when matching for the page path, but not sure if this causes other problems.
const pageId = pagePath.replace('/', '').match(/[^-]*$/);
Thank you for making this repo/project! It's so great and easy to spin up!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.