แบบสำรวจการวิจัย: บอกให้เราทราบเกี่ยวกับประสบการณ์การใช้งาน Blockly
เริ่มแบบสำรวจ
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
blockly > ทั่วไป > createBlockDefinitionsFromJsonArray
ฟังก์ชัน Common.createBlockDefinitionsFromJsonArray()
กำหนดการบล็อกจากอาร์เรย์ของคำจำกัดความบล็อก JSON ตามที่เครื่องมือสำหรับนักพัฒนาซอฟต์แวร์ Blockly อาจสร้างขึ้น
ลายเซ็น:
export declare function createBlockDefinitionsFromJsonArray(jsonArray: any[]): {
[key: string]: BlockDefinition;
};
พารามิเตอร์
พารามิเตอร์ |
ประเภท |
คำอธิบาย |
jsonArray |
ทั้งหมด[] |
อาร์เรย์ของคำนิยามบล็อก JSON |
การคืนสินค้า:
{ [key: string]: BlockDefinition; }
แมปคำจำกัดความของการบล็อกแล้ว
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2024-08-27 UTC
[[["เข้าใจง่าย","easyToUnderstand","thumb-up"],["แก้ปัญหาของฉันได้","solvedMyProblem","thumb-up"],["อื่นๆ","otherUp","thumb-up"]],[["ไม่มีข้อมูลที่ฉันต้องการ","missingTheInformationINeed","thumb-down"],["ซับซ้อนเกินไป/มีหลายขั้นตอนมากเกินไป","tooComplicatedTooManySteps","thumb-down"],["ล้าสมัย","outOfDate","thumb-down"],["ปัญหาเกี่ยวกับการแปล","translationIssue","thumb-down"],["ตัวอย่าง/ปัญหาเกี่ยวกับโค้ด","samplesCodeIssue","thumb-down"],["อื่นๆ","otherDown","thumb-down"]],["อัปเดตล่าสุด 2024-08-27 UTC"],[[["Defines new block types in Blockly based on an array of JSON definitions, commonly generated by the Blockly Developer Tools."],["Takes an array of JSON objects representing block configurations as input."],["Returns a dictionary/map where block type names are keys and corresponding block definitions are values, allowing access and usage of the newly defined blocks."]]],["The `createBlockDefinitionsFromJsonArray` function defines blocks from an array of JSON block definitions. It accepts a `jsonArray` parameter, which is an array of these definitions. The function then returns a map where each key corresponds to a block definition and its value is the associated `BlockDefinition`. This effectively translates a JSON array into a set of usable block definitions.\n"]]