Dhravya / supermemory

Build your own second brain with supermemory. It's a ChatGPT for your bookmarks. Import tweets or save websites and content using the chrome extension.

Home Page:https://supermemory.ai

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Chrome extension has some errors on when loaded locally

faisal00813 opened this issue · comments

I was able to fix these issues by doing the following:

  1. Use "host_permissions" to specify host-specific permissions:
"host_permissions": [
  "http://localhost:3000/*",
  "https://opulent-funicular-94rx4v9w775f96q-3000.app.github.dev/*",
  "https://anycontext.dhr.wtf/*"
],
  1. Simplify permissions:
"permissions": [
  "activeTab",
  "storage"
],
  1. Build using bun build:
mkdir ./build
bun install
bun build ./src/*.tsx --outdir ./build
  1. Paste the built files into ./src
  2. Update manifest.json
    Replacing all .tsx files with the newly built .js files:
{
  "manifest_version": 3,
  "name": "SuperMemory",
  "version": "2.0.0",
  "action": {
    "default_popup": "index.html"
  },
  "icons": {
    "16": "icons/icon16.png",
    "32": "icons/icon32.png",
    "48": "icons/icon48.png",
    "128": "icons/icon128.png"
  },
  "content_scripts": [
    {
      "js": ["src/content.js"],
      "matches": [
        "http://localhost:3000/*",
        "https://opulent-funicular-94rx4v9w775f96q-3000.app.github.dev/*",
        "https://anycontext.dhr.wtf/*",
        "<all_urls>"
      ]
    }
  ],
  "host_permissions": [
    "http://localhost:3000/*",
    "https://opulent-funicular-94rx4v9w775f96q-3000.app.github.dev/*",
    "https://anycontext.dhr.wtf/*"
  ],
  "permissions": [
    "activeTab",
    "storage"
  ],
  "background": {
    "service_worker": "src/background.js"
  }
}
  1. Update the index.html:
    Also replacing with the built .js one:
<!doctype html>
<html lang="en">
  <head>
    <meta charset="UTF-8" />
    <link rel="icon" type="image/svg+xml" href="/vite.svg" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Vite + React + TS</title>
  </head>
  <body>
    <div id="root"></div>
    <script type="module" src="/src/main.js"></script>
  </body>
</html>
  1. Manually load the Chrome extension
  • Turn on Developer Mode
  • Click on the Load unpacked
  • Select the apps/extension folder

After installation, click on the extension icon > Log In.

Still having errors importing Twitter Bookmark though:
Screenshot 2024-04-15 at 16 08 22

Hope it helps.

import from twitter is still in the works, will be perfected very very soon 🙏

Hi! The chrome extension is on the webstore now. See instructions on how to use it here - https://github.com/Dhravya/supermemory?tab=readme-ov-file#how-do-i-use-this