Skip to content

Commit

Permalink
Revert "Update new plugin and extension template mentions to point to…
Browse files Browse the repository at this point in the history
… jspsych-dev"

This reverts commit b243de6.

Changes to be applied in point-templates-to-dev branch instead.
  • Loading branch information
cherriechang committed Feb 6, 2025
1 parent 2feebbf commit 7150920
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
2 changes: 1 addition & 1 deletion docs/developers/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ If you are developing a new plugin or extension there are two different reposito

The main `jspsych` repository is open to new plugins and extensions that are likely to be widely used. We require that contributions to main repository are well documented and tested before they are merged. Contributions to the main repository must use TypeScript. We limit contributions to this repository because once a plugin or extension is in the main codebase we are generally committed to providing updates as we develop new versions of jsPsych. Each new plugin and extension potentially increases the amount of development work that we will need to do in the future, so we are somewhat selective about what we will merge. If you have an idea that you'd like to discuss please [open a discussion thread](https://github.com/jspsych/jsPsych/discussions/new) and we'd love to chat about it!

The `jspsych-contrib` repository is open to any contributions that are complete and working code. There are some minimal guidelines in place about basic documentation that should be provided. Contributors can easily start building a new plugin or extension using our [new-plugin](https://github.com/jspsych/jspsych-dev/tree/main/packages/new-plugin) and [new-extension](https://github.com/jspsych/jspsych-dev/tree/main/packages/new-extension) tools. Both tools run from the command line and will automatically generate a template plugin/extension package, which includes boilerplate code and essential files. Both of these tools also offer TypeScript and JavaScript versions of the generated package to choose from. Check our [plugin developer documentation](https://www.jspsych.org/latest/developers/plugin-development/) for additional guidance.
The `jspsych-contrib` repository is open to any contributions that are complete and working code. There are some minimal guidelines in place about basic documentation that should be provided. Contributors can choose whether to develop their plugin or extension using our [TypeScript template](https://github.com/jspsych/jspsych-contrib/blob/main/templates/plugin-template-ts/src/index.ts) or using our [JavaScript template](https://github.com/jspsych/jspsych-contrib/blob/main/templates/plugin-template-js/src/index.js). Check our [plugin developer documentation](https://www.jspsych.org/latest/developers/plugin-development/) for additional guidance.

Contributions to `jspsych-contrib` are not evaluated for general usefulness in the same way that contributions to the main repository are. We also periodically consider whether to move contributions into the main repository from `jspsych-contrib` based on their popularity and completeness (documentation and testing).

Expand Down
2 changes: 1 addition & 1 deletion docs/developers/extension-development.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ As of version 7.0, extensions are [JavaScript Classes](https://developer.mozilla

### Templates

Plugins can be written in either plain JavaScript or in TypeScript. Template files for both [JavaScript](https://github.com/jspsych/jspsych-dev/blob/main/packages/new-extension/templates/extension-template-js/src/index.js) and [TypeScript](https://github.com/jspsych/jspsych-dev/blob/main/packages/new-extension/templates/extension-template-ts/src/index.ts) are available in the [jspsych-dev repository](https://github.com/jspsych/jspsych-dev/).
Plugins can be written in either plain JavaScript or in TypeScript. Template files for both [JavaScript](https://github.com/jspsych/jspsych-contrib/blob/main/packages/extension-template/index.js) and [TypeScript](https://github.com/jspsych/jspsych-contrib/blob/main/packages/extension-template-ts/src/index.ts) are available in the [jspsych-contrib repository](https://github.com/jspsych/jspsych-contrib/).

## Extension components

Expand Down
4 changes: 2 additions & 2 deletions docs/developers/plugin-development.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,9 @@ As of version 7.0, plugins are [JavaScript Classes](https://developer.mozilla.or

## Plugin templates

Templates for plugins are available in the [jspsych-dev](https://github.com/jspsych/jspsych-dev) repository. Plugins can be written in either plain [JavaScript](https://github.com/jspsych/jspsych-dev/tree/main/packages/new-plugin/templates/plugin-template-js/src/index.js) or in [TypeScript](https://github.com/jspsych/jspsych-dev/tree/main/packages/new-plugin/templates/plugin-template-ts/src/index.ts).
Templates for plugins are available in the [jspsych-contrib](https://github.com/jspsych/jspsych-contrib) repository. Plugins can be written in either plain [JavaScript](https://github.com/jspsych/jspsych-contrib/blob/main/templates/plugin-template-js/src/index.js) or in [TypeScript](https://github.com/jspsych/jspsych-contrib/blob/main/templates/plugin-template-ts/src/index.ts).

To get started with a template, we recommend using the CLI tools that we have published in jspsych-dev. These tools automate the setup of a new plugin in either JavaScript or TypeScript. Additional information about the CLI tools is available in the [`README`](https://github.com/jspsych/jspsych-dev/blob/main/README.md) of jspsych-dev.
To get started with a template, we recommend using the CLI tool that we have published in jspsych-contrib. This automates the setup of a new plugin in either JavaScript or TypeScript. Additional information about the CLI tool is available in the [`README`](https://github.com/jspsych/jspsych-contrib?tab=readme-ov-file#creating-a-new-plugin-or-extension) of jspsych-contrib.

## Plugin components

Expand Down
4 changes: 2 additions & 2 deletions docs/support/migration-v7.md
Original file line number Diff line number Diff line change
Expand Up @@ -114,11 +114,11 @@ var trial = {

## Custom plugins

If you have custom plugins that you would like to upgrade to be compatible with v7.x we recommend using our [plugin template](https://github.com/jspsych/jspsych-dev/tree/main/packages/new-plugin/templates).
If you have custom plugins that you would like to upgrade to be compatible with v7.x we recommend using our [plugin template](https://github.com/jspsych/jspsych-contrib/blob/main/packages/plugin-template/index.js).

The new template implements plugins as a class, but the core components are essentially unchanged.

* Anything in `plugin.info` from a v6.x plugin should be moved into the `info` object. Note that the `type` argument for the parameters follows a slightly different syntax in the v7.x plugins. This object is then [assigned as a static property of the class](https://github.com/jspsych/jspsych-dev/blob/main/packages/new-plugin/templates/plugin-template-js/src/index.js#L58).
* Anything in `plugin.info` from a v6.x plugin should be moved into the `info` object. Note that the `type` argument for the parameters follows a slightly different syntax in the v7.x plugins. This object is then [assigned as a static property of the class](https://github.com/jspsych/jspsych-contrib/blob/6a27c3fc72fdb1feb1a4041cd670775a7c4bf51d/packages/plugin-template/index.js#L39).
* Anything in `plugin.trial` from a v6.x plugin should be moved into the `trial` method inside the class.
* The new template has a `constructor()` function that accepts an instance of jsPsych. You do not need to adjust this portion of the plugin.

Expand Down

0 comments on commit 7150920

Please sign in to comment.