Skip to content
New issue

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

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

Already on GitHub? # to your account

bug: logLevel enum is not exported #30255

Open
3 tasks done
5im0n opened this issue Mar 14, 2025 · 0 comments
Open
3 tasks done

bug: logLevel enum is not exported #30255

5im0n opened this issue Mar 14, 2025 · 0 comments
Labels

Comments

@5im0n
Copy link
Contributor

5im0n commented Mar 14, 2025

Prerequisites

Ionic Framework Version

v8.x

Current Behavior

The release of Ionic 8.5.0 introduced the logLevel option in IonicConfig.

However, the LogLevel enum is not exported by the @ionic/core module.
As a result, we are unable to use LogLevel.OFF (or any other value from LogLevel) when defining the logLevel property in IonicConfig.

We can't configure it

import { IonicConfig, LogLevel } from '@ionic/core'; // Error LogLevel  is not exported

export const ionicConfig: IonicConfig = {
  logLevel: LogLevel.OFF,
  mode: 'md',
  spinner: 'lines',
  swipeBackEnabled: false,
};

Expected Behavior

The LogLevel enum should be properly exported by @ionic/core, allowing developers to set the logLevel in IonicConfig without any import issues.

import { IonicConfig, LogLevel } from '@ionic/core';

const config: IonicConfig = {
  logLevel: LogLevel.OFF, // ✅ This should work without any import issues
  mode: 'md',
  spinner: 'lines',
  swipeBackEnabled: false,
};

Steps to Reproduce

  1. Install or upgrade to @ionic/core version 8.5.0.
  2. Import LogLevel from @ionic/core in a TypeScript file.
  3. Define logLevel: LogLevel.OFF inside IonicConfig.
  4. Observe that TypeScript raises an error due to LogLevel not being exported.

Code Reproduction URL

https://stackblitz.com/edit/ykhte9q1?file=src%2Fmain.ts

Ionic Info

Ionic:

Ionic CLI : 7.2.0

Utility:

cordova-res : not installed globally
native-run : not installed globally

System:

NodeJS : v20.18.3
npm : 11.1.0
OS : Windows 10

Additional Information

No response

@ionitron-bot ionitron-bot bot added the triage label Mar 14, 2025
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant