mirror of
https://github.com/bilawalsidhu/gods-eye-view.git
synced 2026-11-05 19:04:02 +00:00
refactor: separate traffic and bikeshare components
This commit is contained in:
1 parent
3143d00c90
commit
903fe6ba37
45 files changed
+6159
-4363
No files matched your search
@@ -15,6 +15,8 @@ export function readLayerSource(file) {
|
||||
'rocketLaunches.js',
|
||||
'militaryInstallations.js',
|
||||
'militaryAwareness.js',
|
||||
'traffic.js',
|
||||
'bikeshare.js',
|
||||
].includes(basename(path))
|
||||
)
|
||||
return readFileSync(path, 'utf8');
|
||||
@@ -34,7 +36,11 @@ export function readLayerSource(file) {
|
||||
? '../layers/installations'
|
||||
: basename(path) === 'militaryAwareness.js'
|
||||
? '../layers/awareness'
|
||||
: '../layers/vessels',
|
||||
: basename(path) === 'traffic.js'
|
||||
? '../layers/traffic'
|
||||
: basename(path) === 'bikeshare.js'
|
||||
? '../layers/bikeshare'
|
||||
: '../layers/vessels',
|
||||
);
|
||||
return readdirSync(directory)
|
||||
.filter((name) => name.endsWith('.js'))
|
||||
|
||||
Reference in new issue
Block a user