Addressed minor pr comments

This commit is contained in:
vzhang03 2024-06-27 14:58:35 -04:00
parent c2ee292b56
commit e7a4ad9156
4 changed files with 5 additions and 30 deletions

View File

@ -14,19 +14,9 @@
const metadata_options = {
randomField: "this is a field",
author: {
"John Cena": {
name: "John Cena",
givenName: "Sammy Salami",
},
"Darnell": {
givenName: "bob",
},
"Bob": "Bob",
"Joe": {
name: "Joe",
},
"Ostrich": {
bbqblaster: 10,
"John": {
name: "John",
givenName: "Johnathan",
},
},
variables: {
@ -35,21 +25,9 @@
"chat-plugin": "this chat plugin allows you to talk to gpt!",
}
},
"time_elapsed": {
bbq: "indicates the number of barbeques",
description: {
"chat-plugin": "this chat plugin allows you to talk to gpt!",
"donut-plugin": "this plugin lets you eat donuts!",
"bbq-plugin": "this plugin lets you spell barbeque",
}
},
"trial_index": {
value: "NEW VALUE",
bbq: "number of barbeques per sq ft",
name: "index",
donuts: "Number of donuts",
},
},
}

View File

@ -144,9 +144,7 @@ export type UniversalPluginParameters = InferredParameters<typeof universalPlugi
export interface PluginInfo {
name: string;
version?: string;
parameters: ParameterInfos;
data?: ParameterInfos;
}
export interface JsPsychPlugin<I extends PluginInfo> {

View File

@ -1,7 +1,7 @@
{
"name": "@jspsych/metadata",
"version": "0.0.1",
"description": "jsPsych plugin for creating and customizing metadata according to Psych-DS standards.",
"description": "jsPsych package for creating and customizing metadata according to Psych-DS standards.",
"type": "module",
"main": "dist/index.cjs",
"exports": {

View File

@ -18,7 +18,6 @@ export class PluginCache {
async getPluginInfo(pluginType: string, variableName: string) {
// fetches if it doesn't exist
if (!(pluginType in this.pluginFields)) {
console.log("doesn't exist -- plugintype:", pluginType, "variableName:", variableName); // checking search
const fields = await this.generatePluginFields(pluginType);
this.pluginFields[pluginType] = fields;
}
@ -57,7 +56,7 @@ export class PluginCache {
pluginType,
"with error",
error,
"If you are using a plugin not in the main JsPsych branch it will not automatically fetch."
"Note: if you are using a plugin not in the main JsPsych branch this will always fail."
);
return undefined;
}