Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
renderjs
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Gabriel Monnerat
renderjs
Commits
00db435a
Commit
00db435a
authored
Dec 12, 2016
by
Sebastian
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
modified renderjs.js, tests soon
parent
b3ca6f36
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
22 additions
and
2 deletions
+22
-2
renderjs.js
renderjs.js
+22
-2
No files found.
renderjs.js
View file @
00db435a
...
@@ -132,7 +132,8 @@
...
@@ -132,7 +132,8 @@
scope_increment
=
0
,
scope_increment
=
0
,
isAbsoluteOrDataURL
=
new
RegExp
(
'
^(?:[a-z]+:)?//|data:
'
,
'
i
'
),
isAbsoluteOrDataURL
=
new
RegExp
(
'
^(?:[a-z]+:)?//|data:
'
,
'
i
'
),
is_page_unloaded
=
false
,
is_page_unloaded
=
false
,
error_list
=
[];
error_list
=
[],
bootstrap_deferred_object
=
new
RSVP
.
defer
();
window
.
addEventListener
(
'
error
'
,
function
(
error
)
{
window
.
addEventListener
(
'
error
'
,
function
(
error
)
{
error_list
.
push
(
error
);
error_list
.
push
(
error
);
...
@@ -1286,6 +1287,16 @@
...
@@ -1286,6 +1287,16 @@
// Bootstrap process. Register the self gadget.
// Bootstrap process. Register the self gadget.
///////////////////////////////////////////////////
///////////////////////////////////////////////////
// Manually initializes the self gadget if the DOMContentLoaded event
// is triggered before everything was ready.
// (For instance, the HTML-tag for the self gadget gets inserted after
// page load)
renderJS
.
manualBootstrap
=
function
()
{
bootstrap_deferred_object
.
resolve
();
};
function
bootstrap
()
{
function
bootstrap
()
{
var
url
=
removeHash
(
window
.
location
.
href
),
var
url
=
removeHash
(
window
.
location
.
href
),
TmpConstructor
,
TmpConstructor
,
...
@@ -1598,7 +1609,16 @@
...
@@ -1598,7 +1609,16 @@
throw
e
;
throw
e
;
});
});
}
}
document
.
addEventListener
(
'
DOMContentLoaded
'
,
init
,
false
);
document
.
addEventListener
(
'
DOMContentLoaded
'
,
bootstrap_deferred_object
.
resolve
,
false
);
// Return Promies/Queue here instead of directly calling init()
return
new
RSVP
.
Queue
()
.
push
(
function
()
{
return
bootstrap_deferred_object
.
promise
;
})
.
push
(
function
()
{
return
init
();
});
});
});
loading_gadget_promise
loading_gadget_promise
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment