Strange behaviour of http.createServer #697
              
                Unanswered
              
          
                  
                    
                      espruino-discuss
                    
                  
                
                  asked this question in
                JavaScript
              
            Replies: 2 comments
-
| Posted at 2017-03-10 by @gfwilliams It fails on linux too. It's because  It's not a bug, it's just part of JS. Rename   | 
Beta Was this translation helpful? Give feedback.
                  
                    0 replies
                  
                
            -
| Posted at 2017-03-11 by JumJum Sometimes life can be so easy, once you know how to live. | 
Beta Was this translation helpful? Give feedback.
                  
                    0 replies
                  
                
            
  
    Sign up for free
    to join this conversation on GitHub.
    Already have an account?
    Sign in to comment
  
        
    
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2017-03-10 by JumJum
Attached code runs fine, but after moving everything into an object, by removing comments, fails with this error.
Uncaught Error: Function "listen" not found!
at line 13 col 10
}).listen(8080);
Got this problem on ESP32, could not test on other board. @gordon, if this is an ESP32 only problem, please move it to that category :-)
Tested this 10 times with both options and always got same result.
Beta Was this translation helpful? Give feedback.
All reactions