I’ve set up a new dev environment for working on plugins. Discourse is up to date with the main branch.
I need to restart Ember in order to test changes made to the front end. This includes changes to Handlebars, Emberjs, and stylesheets. A few months ago, when I was working on plugins, I only needed to reload the web page to test these changes.
Has something changed in this time? Is this something wrong with my environment?
Any help is much appreciated!
Changes to frontend code should only require a refresh of the page. In fact, a change to JS code should actually trigger a browser refresh automatically.
So it sounds like something is wrong with your environment. Did you follow one of the development installation guides here on Meta?
That’s along the lines of what I figured it should occur.
This is the installation guide I followed. I should mention I am using an Ubuntu subsystem with Windows 11 WSL.
This guide covers installation instructions in development environment, for a production guide see: Install Discourse in production with the official, supported instructions
So you want to set up Discourse on Ubuntu to hack on and develop with?
We’ll assume that you don’t have Ruby/Rails/Postgres/Redis installed on your Ubuntu system. Let’s begin!
Although this guide assumes that you are using Ubuntu, but the set-up instructions will work fine for any Debian based distribution. …
Ended up finding the issue: My environment had some symbolic links that (I assume) were messing up file change detections.
The discourse and my-plugin directories were under my Windows user, with symbolic links in the WSL Ubuntu (/home/silk/discourse → /mnt/c/Users/SilK/discourse).
The resolution was to have the true directories exist in the WSL Ubuntu environment, and create Windows symbolic links (C:\Users\SilK\discourse → \wsl.localhost\Ubuntu-20.04\home\silk\discourse).