Plugin API documentations?

Sorry if this has been asked, I tried searching for documentations but all I can find is the Get Started post, it helped me create a plugin but it didn’t cover topics such as what APIs are available. So, are there documents at all?

Thanks!

「いいね!」 5

Api documentation is available at
http://docs.discourse.org

「いいね!」 5

Discourse API doc is not what I’m requesting. I was thinking about something like Chrome plugin development docs or WordPress plugin development docs. For example when I read the Beginner’s Guide to Creating Discourse Plugins, I have questions like what are other special properties and callbacks does Discourse recognize in the default module? or what parameters are passed into the initialize() method? Neither the guide nor docs.discourse.org answered those questions.

「いいね!」 3

As discourse uses ember in frontend and rails in backend, you can browse their respective docs to know how to create components, or controllers, etc.

That being said, you can go through the code of discourse to learn how they are doing things.

I had asked similar question long time back… See if the answers given here help you.

「いいね!」 4

Then those questions are probably good candidates for dev :slight_smile:

このスレッドを再浮上させます。まだ回答がないので :slight_smile:

「いいね!」 1

@bcartwri96 要するに、Discourse のプラグイン API に関する包括的なドキュメントがほとんど存在しないというのが現状だと思います。

Meta には Developing Discourse Plugins - Part 1 - Create a basic plugin のような断片的な情報はありますが、それらしい包括的な API リファレンスはないようです。一部は純粋な Ember や Rails の仕組みですが、その間には Discourse 独自の慣習に基づく部分が非常に多く存在します。

将来的には、コミュニティがこのギャップを埋める「Discourse 開発者マニュアル」の作成に取り組むと良いと思います。私たちは Pavilion に HOWTO の断片をいくつか実装しており、これらの作業がより包括的なリファレンスガイドを開発するための初期の基礎となることを願っています。

「いいね!」 4

このファイルをチェックしてください。ほとんどのメソッドは簡潔にドキュメント化されています
https://github.com/discourse/discourse/blob/master/app/assets/javascripts/discourse/app/lib/plugin-api.js

「いいね!」 9

このファイルは blob/main/app/assets/javascripts/discourse/app/lib/plugin-api.gjs に移動しました

「いいね!」 5