mirror of
				https://github.com/zulip/zulip.git
				synced 2025-11-03 21:43:21 +00:00 
			
		
		
		
	refactor: Extract settings_config.
This moves some code from settings_display.js
into the new module settings_config.js.
Extracting this module breaks some dependencies
on settings_display.js (which has some annoying
transitive dependencies, including jQuery).
In particular this isolates stream_data from
from settings_display.js.
Two of the three structures that we moved here
weren't even directly used by settings_display.js,
since we do a lot of rendering in the modules
admin.js and setting.js.
We make get_all_display_settings() a function
to avoid a require-time dependency on page_params.
Breaking the dependencies simplifies a few
node tests.
Most of the node test complexity came from the
following commit in March 2019:
5a130097bf
The commit itself seems harmless enough, but
dependencies can have a somewhat "viral" nature,
where making stream_data depend on settings_display
caused us to modify four different node tests.
			
			
This commit is contained in:
		@@ -111,6 +111,7 @@ EXEMPT_FILES = {
 | 
			
		||||
    'static/js/server_events.js',
 | 
			
		||||
    'static/js/settings_account.js',
 | 
			
		||||
    'static/js/settings_bots.js',
 | 
			
		||||
    'static/js/settings_config.js',
 | 
			
		||||
    'static/js/settings_display.js',
 | 
			
		||||
    'static/js/settings_emoji.js',
 | 
			
		||||
    'static/js/settings_exports.js',
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user