detecting resource not loaded errors, fixes #5
example loading css dynamically