From ca6c4eb63b4e71af18bee169fa9e13ffbcb22dee Mon Sep 17 00:00:00 2001 From: Cherrie Chang Date: Wed, 18 Dec 2024 16:50:24 -0500 Subject: [PATCH] add docstring in JsPsych.ts for getCitations() --- packages/jspsych/src/JsPsych.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/packages/jspsych/src/JsPsych.ts b/packages/jspsych/src/JsPsych.ts index 4188653e4a..eeff974de2 100644 --- a/packages/jspsych/src/JsPsych.ts +++ b/packages/jspsych/src/JsPsych.ts @@ -261,6 +261,14 @@ export class JsPsych { return this.timeline?.description.timeline; } + /** + * Prints out a string containing citations for the jsPsych library and all input plugins/extensions in the specified format. + * If called without input, prints citation for jsPsych library. + * + * @param plugins The plugins/extensions to generate citations for. Always prints the citation for the jsPsych library at the top. + * @param format The desired output citation format. Currently supports "apa" and "bibtex". + * @returns String containing citations separated with newline character. + */ getCitations( plugins: Array> | Class> = [], format: "apa" | "bibtex" = "apa"