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

Creating a module tutorial #261

Open
wants to merge 26 commits into
base: main
Choose a base branch
from

Conversation

robbiejackson
Copy link
Contributor

First step of module development tutorial.

Pull request created so that I can check the docusaurus presentation.

I'll be adding further tutorial steps to the same pull request.

@HLeithner HLeithner changed the title step1 Creating a module tutorial May 21, 2024

```php
$document = $this->app->getDocument();
$document->addScriptOptions('vars', array('suffix' => "!"));
Copy link
Member

@Fedik Fedik May 25, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to use mod_hello.vars as the options name (prefixed by extension name) for the tutorial.
It is not strict but recommended approach. Because it is global storage of the options and "very generic" option name can collide with another extension.

Then, when people will copy/paste this tutorial, they will doing it "right" 😉

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

Successfully merging this pull request may close these issues.

None yet

2 participants