discourse/plugins/discourse-hcaptcha
Jarek Radosz d10c1e57e8
DEV: Overhaul typechecking configuration (#35794)
- Switches to typescript 'composite project' mode for improved
organization & performance
- Generates declarations from core modules, and outputs to a new
`@discourse/types` package
- Introduces tsconfigs for core plugins, which leans on that new
`@discourse/types` package
- In future, we plan to publish this discourse-types package for other
themes/plugins to use

The motivation at this stage is primarily to improve editor
autocompletion. We provide absolutely no guarantees about the accuracy
or stability of the generated types.

For now, some issues have been resolved by adding manual `@type`
declarations.

In particular, extensionless imports of `.gjs` files are broken when
running in composite-project mode, so in those cases we have to add
manual `@type {import("./the-file.gjs").default}` declarations.
Unfortunately this failure does not show up in IDEs. We hope to get this
resolved soon.

---------

Co-authored-by: David Taylor <david@taylorhq.com>
Co-authored-by: Chris Manson <chris@manson.ie>
2025-11-12 12:54:34 +00:00
..
app DEV: Clean up scope resolution operators in plugins (#34979) 2025-09-30 14:36:34 +02:00
assets DEV: Enable ember/no-classic-components (#33978) 2025-07-30 14:54:24 +02:00
config DEV: add missing flag for site settings (#35626) 2025-10-28 10:08:25 +04:00
db
lib/discourse_hcaptcha DEV: Remove unnecessary freeze calls (#35064) 2025-09-30 15:36:16 +02:00
spec FIX: Hcaptcha plugin was incompatible with login-required sites (#34181) 2025-08-08 14:37:57 -04:00
test/javascripts
package.json DEV: Overhaul typechecking configuration (#35794) 2025-11-12 12:54:34 +00:00
plugin.rb DEV: Clean up requires (#34946) 2025-09-24 12:00:22 +02:00
README.md
tsconfig.json DEV: Overhaul typechecking configuration (#35794) 2025-11-12 12:54:34 +00:00

Discourse hCaptcha Plugin

Overview

This plugin is designed to integrate HCaptcha into the sign-up form of Discourse forums. This plugin aims to enhance security and bot protection by leveraging the privacy-centric features of HCaptcha. The setup process is straightforward and consists of a few easy steps.

Installation

  1. Create an HCaptcha Account:

    • Visit HCaptcha to create an account. After registering, you'll receive a site key and a secret key.
  2. Setup Local Testing (Optional):

    • If you are testing locally, add a new virtual host entry to your hosts file. Include a line like 127.0.0.1 test.mydomain.com. Make sure the domain is valid, even if you don't own it, to ensure the HCaptcha script loads properly.
  3. Configure Plugin Settings:

    • Log into your Discourse admin panel.
    • Navigate to Admin > Settings > Plugins > hCaptcha (settings).
    • In this section, add the site key and secret key you obtained from HCaptcha.

By completing these steps, you will successfully integrate HCaptcha into the sign-up form of your community.