Opened 8 years ago

Closed 8 years ago

Last modified 8 years ago

#13497 closed defect (duplicate)

Bug of TableContainer with AMD Asynchronous Loading

Reported by: zhangzxm Owned by:
Priority: high Milestone: tbd
Component: DojoX Layout Version: 1.7.0b1
Keywords: Cc:
Blocked By: Blocking:

Description

I tried to use TableContainer? with async:true, and got an error "dojo is not defined". I saw that the TableContainer? is not defined with AMD specification which maybe the reason of this error.

<?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE html PUBLIC "-W3CDTD XHTML 1.1EN" "http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd" > <html xmlns="http://www.w3.org/1999/xhtml"> <head>

<title>Test Dojo AMD Asynchronous Loading</title> <link rel="stylesheet" type="text/css" href="dojotoolkit/dijit/themes/claro/claro.css" /> <script type="text/javascript">

var djConfig={locale:"en-us",isDebug:true,async:true};

</script> <script type="text/javascript" src="dojotoolkit/dojo/dojo.js"></script> <script type="text/javascript">

require(dojox/layout/TableContainer?, function() {

dojo.ready(function() {

The following codes cause an error: 'dojo is not defined' new dojox.layout.TableContainer?({

"cols" : 1, "style" : "border: 1px solid blue;"

}, "tableContainer").startup();

Cannot reach here. console.debug('Success!');

});

});

</script>

</head> <body class="claro">

<div id="tableContainer"><h2>Hello</h2></div>

</body> </html>

Change History (2)

comment:1 Changed 8 years ago by Adam Peller

Resolution: duplicate
Status: newclosed

Yes, much work remains to convert dojox modules to AMD. Dup of #12863

comment:2 Changed 8 years ago by Adam Peller

Component: GeneralDojoX Layout
Note: See TracTickets for help on using tickets.