On MacOS, I'm developing an Office Word add-in. All has been going well until this morning when I woke up myself and my laptop, fired up the add-in (npm start), and clicked on the add-in in the ribbon at which point I got the message:
"sorry, we can't load add-in. Please make sure that you have network and/or Internet connectivity . . ."
This occurs not only with the add-in I'm developing but also with the test add-in that comes with yeoman.
Things I've tried (on both my add-in and the Yeoman-supplied one):
- npm run dev-server – compiles successfully, reporting "Project is running at https://localhost:3000/"
- reboot of computer
- netstat -vanp tcp | grep 3000 – reports nothing.
- restart my XAMPP server
- npm run validate – successul validation of manifest.xml
- https://localhost – produces the dashboard of XAMPP
- https://localhost:3000 – produces 'Unable to connect' although at one point I did get a listing of files and their icons in the add-in (but still the error message in Word).
- npm start – (several times including shutting down Word beforehand).
EDIT: I have, just after posting the above, noticed that if I do the following:
'npm run dev-server' (while Word is running and the add-in is in the ribbon), the add-in will load correctly and function. https://localhost:3000 in the web browser now displays the files and icons.
If I follow 'npm run dev-server' with 'npm start' (while Word is running and the add-in has been loaded from 1. above), I can continue to use the add-in. If I close the add-in and attempt to open it again, I get the error message.
If I close Word and run 'npm run dev-server' then 'npm start', I get the error message when clicking on the add-in the ribbon.
Running 'npm run dev-server' and trying https://localhost:3000 in the web browser works, then 'npm start' and https://localhost:3000 no longer connects.
'npm start' reports: office-addin-taskpane-js@0.0.1 start office-addin-debugging start manifest.xml Debugging is being started... App type: desktop Sideloading the Office Add-in... Debugging started.
For the past few weeks, from the terminal I have been just running 'npm start' with no problems until this morning. It appears that 'npm start' is suddenly shutting down its own server.
All help and advice gratefully received.