Skip to content

A tool for reviewing Articles for Creation submissions on the English Wikipedia

License

Notifications You must be signed in to change notification settings

wikimedia-gadgets/afc-helper

Repository files navigation

afc-helper [Build Status]

A tool for reviewing Articles for Creation submissions on the English Wikipedia, rewritten using clear, object-oriented JavaScript with a focus on killing bloat while adding value.

Using

The script can be installed on the English Wikipedia by following the instructions at WP:AFCH.

Contributing

Looking for detailed instructions about how to contribute to afc-helper? Check out the Contributing page on Wikipedia!

Your contributions are welcome! Please add feature requests and bug reports to WT:AFCH on enwiki to keep discussions centralized; GitHub also works.

If you'd like to contribute directly to the code, that's great too! In order to maintain great code quality, please submit significant changes using pull requests so that a consistent code style can be maintained throughout the project.

To serve the script locally for development, use npm start and follow the instructions. The Contributing page has more details if you get stuck.

Protip for developers: AFCH running using npm start will run in silent mode by default. That is, it will not edit any pages, but instead will output API queries to your browser console. To turn this off, add window.afchSuppressDevEdits = false; to your common.js file, or open a browser console and type AFCH.consts.mockItUp = false;

Testing

We have unit tests! afc-helper uses Jest for testing, a framework built on top of Jasmine that offers dead-simple mocking, built-in simulated DOM manipulation using jsdom, and more.

Tests are stored in the tests directory and are run automatically on new commits via GitHub Actions.

Deploying

Interface administrators can click here for a detailed work instruction of how to deploy to English Wikipedia.

To deploy AFC Helper to a wiki, use scripts/upload.py.

Dependencies

Below is a list of dependencies and what they are involved with, so you know what to test when updating dependencies.

  • Regular
    • hogan.js - HTML template framework. Creates code that ends up on-wiki.
  • Dev Only
    • eslint - Used by CI and code editor
    • grunt - Used by CI and npm start
    • jest-cli - Used by CI and unit tests
    • jquery - Used by CI and unit tests

License

afc-helper is licensed under the GNU General Public License version 3; see LICENSE for more information.