diff --git a/src/nginxconfig/templates/domain.vue b/src/nginxconfig/templates/domain.vue index a92cd9b..d160323 100644 --- a/src/nginxconfig/templates/domain.vue +++ b/src/nginxconfig/templates/domain.vue @@ -63,13 +63,12 @@ THE SOFTWARE. import analytics from '../util/analytics'; import isChanged from '../util/is_changed'; import Presets from './domain_sections/presets'; - import * as Sections from './domain_sections'; + import Sections from './domain_sections'; - const tabs = Object.values(Sections); const delegated = { hasUserInteraction: false, presets: Presets.delegated, - ...tabs.reduce((prev, tab) => { + ...Sections.reduce((prev, tab) => { prev[tab.key] = tab.delegated; return prev; }, {}), @@ -86,8 +85,8 @@ THE SOFTWARE. }, data() { return { - active: tabs[0].key, - tabs, + active: Sections[0].key, + tabs: Sections, }; }, computed: { diff --git a/src/nginxconfig/templates/domain_sections/index.js b/src/nginxconfig/templates/domain_sections/index.js index 8f2269e..b808f78 100644 --- a/src/nginxconfig/templates/domain_sections/index.js +++ b/src/nginxconfig/templates/domain_sections/index.js @@ -1,5 +1,5 @@ /* -Copyright 2020 DigitalOcean +Copyright 2021 DigitalOcean This code is licensed under the MIT License. You may obtain a copy of the License at @@ -24,12 +24,14 @@ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. */ -export { default as Server } from './server'; -export { default as HTTPS } from './https'; -export { default as PHP } from './php'; -export { default as Python } from './python'; -export { default as ReverseProxy } from './reverse_proxy'; -export { default as Routing } from './routing'; -export { default as Logging } from './logging'; -export { default as Restrict } from './restrict'; -export { default as Onion } from './onion'; +import Server from './server'; +import HTTPS from './https'; +import PHP from './php'; +import Python from './python'; +import ReverseProxy from './reverse_proxy'; +import Routing from './routing'; +import Logging from './logging'; +import Restrict from './restrict'; +import Onion from './onion'; + +export default [ Server, HTTPS, PHP, Python, ReverseProxy, Routing, Logging, Restrict, Onion ]; diff --git a/src/nginxconfig/templates/global.vue b/src/nginxconfig/templates/global.vue index cb3bd2c..d96e7b9 100644 --- a/src/nginxconfig/templates/global.vue +++ b/src/nginxconfig/templates/global.vue @@ -56,10 +56,9 @@ THE SOFTWARE.