Skip to content

[FEATURE] Add importFromFile option to support importing existing tsconfig files#26

Open
creifenscheid wants to merge 1 commit intob13:mainfrom
creifenscheid:main
Open

[FEATURE] Add importFromFile option to support importing existing tsconfig files#26
creifenscheid wants to merge 1 commit intob13:mainfrom
creifenscheid:main

Conversation

@creifenscheid
Copy link
Copy Markdown

Summary

Currently, the settings configuration is converted into tsconfig entries using a simple key = value mapping.
Because of this, there is no way to reference or reuse an existing tsconfig file via an @import statement.

What this PR does

This PR introduces a new configuration key: importFromFile

When importFromFile is set, the provided file path is converted into a valid @import statement, e.g.

@import "EXT:my_extension/Configuration/TsConfig/user.tsconfig"

This import is then applied to the generated group tsconfig, allowing existing tsconfig files to be reused instead of duplicating configuration values.

@bmack
Copy link
Copy Markdown
Member

bmack commented Feb 6, 2026

Hey,

thank you for your pull request.
Your approach might have side-effects, as it conflicts with options that are on the same level, as the config options below settings are used directly. Also, you can only include one file this way.

How about we do something like:

settings:
    options:
        createFoldersInEB: true
    TCEMAIN:
        clearCache: all

settingsFromFiles:
    - 'EXT:my_extension/Configuration/TSconfig/user.tsconfig'

@creifenscheid
Copy link
Copy Markdown
Author

Hi Benny,

Thanks for your reply!
I get your point.
I had been thinking about the single-file approach as well, but I assumed that most integrators already have one user.tsconfig file that would need to be imported. That’s why I was okay with supporting just one file.

That said, you’re right — allowing multiple files gives more flexibility and more possibilities.

Do we need to consider the order in which settings and files are applied?
In my opinion, the imported file(s) should be processed first, and then the explicit settings. This would allow the settings to override values from the file. Or am I missing something?

Have a great weekend!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants