Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create a new SettingsManager. #51

Merged
merged 3 commits into from
Feb 9, 2024
Merged

Create a new SettingsManager. #51

merged 3 commits into from
Feb 9, 2024

Commits on Feb 6, 2024

  1. Create a new SettingsManager. Similar to Logger, it is a singleton. I…

    …mplement it in ObsidianIcalPlugin so that it can be used anywhere. Change everywhere so that we are using the new getSetting and setSetting functions.
    
    Now SettingsManager acts as a cache layer between the application and the plugin saveData and loadData functions.
    
    Fixes a bug where settings were not loading properly when new settings were added after a version upgrade.
    
    Fixes a bug where changing a value of a setting was not reflected through the code.
    andrewbrereton committed Feb 6, 2024
    Configuration menu
    Copy the full SHA
    210a5e2 View commit details
    Browse the repository at this point in the history

Commits on Feb 7, 2024

  1. Change SettingsManager to use Typescript getter and setter functions …

    …for each setting. Although this is more lines of code, it means that every setting is an explicit and strongly-typed property.
    
    Also modified instantiation so that the settings object is all you need to use the SettingsManager.
    
    Update settings implementation everywhere to use the new method.
    andrewbrereton committed Feb 7, 2024
    Configuration menu
    Copy the full SHA
    7bfcca5 View commit details
    Browse the repository at this point in the history

Commits on Feb 9, 2024

  1. Configuration menu
    Copy the full SHA
    e556166 View commit details
    Browse the repository at this point in the history