Skip to content
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

Hook (via use-package) for markdown-mode not working #7

Open
buhtz opened this issue Jan 5, 2023 · 3 comments
Open

Hook (via use-package) for markdown-mode not working #7

buhtz opened this issue Jan 5, 2023 · 3 comments
Labels
documentation Improvements or additions to documentation

Comments

@buhtz
Copy link

buhtz commented Jan 5, 2023

I setup your package like this

(use-package impatient-showdown
  :hook
  (markdown-mode-hook . impatient-showdown-mode)
  :init
  (setq impatient-showdown-background-color "#9d9d9d")
  (setq impatient-showdown-markdown-background-color "#f7f1ec")
  )

When opening md files (entering markdown-mode) the hook seems not to be triggered. Or something is wrong on my code?
Explicit activating your mode via M-x impatient-showdown-mode works fine.

@jcs090218
Copy link
Member

I think in use-package, you should not add -hook at the end. It should be:

(use-package impatient-showdown
  :hook
  (markdown-mode . impatient-showdown-mode)
  ...

@buhtz
Copy link
Author

buhtz commented Jan 5, 2023

Great thats it.
I assume a lot of new users would appreciate if you would add the how-to-install-and-use-with use-package to your README.

@jcs090218 jcs090218 added the documentation Improvements or additions to documentation label Jan 5, 2023
@jcs090218
Copy link
Member

Yeah, I agree. Feel free to open PRs for this! 👍

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

2 participants