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

Error / warning when importing useQMarkdownGlobalProps #388

Open
maiolica opened this issue Oct 11, 2023 · 0 comments
Open

Error / warning when importing useQMarkdownGlobalProps #388

maiolica opened this issue Oct 11, 2023 · 0 comments

Comments

@maiolica
Copy link

maiolica commented Oct 11, 2023

Describe the bug
I am using @quasar/app-webpack 3.11.2 with @quasar/quasar-app-extension-qmarkdown 2.0.0-beta.10 with TypeScript.
I need to set a global default value for Qmarkdown, and following the docs (https://qmarkdown.netlify.app/developing/using-qmarkdown#Global-Properties), this is the boot file I have created:

import { useQMarkdownGlobalProps } from '@quasar/quasar-ui-qmarkdown';
import { boot } from 'quasar/wrappers';

const markdown = useQMarkdownGlobalProps({
  noHtml: false,
});

export default boot(({ app }) => {
  app.use(markdown);
});

I am receiving an error and a warning:

  1. Module '"@quasar/quasar-ui-qmarkdown"' has no exported member 'useQMarkdownGlobalProps'.

If I ignore the error, code is working fine, there is indeed a useQMarkdownGlobalProps function that can be imported.
I've solved this by using import QMarkdown from '@quasar/quasar-ui-qmarkdown'; and forcing a type on QMarkdown.useQMarkdownGlobalProps, a quick hack, but it works.

  1. [Vue warn]: A plugin must either be a function or an object with an "install" function.

This seems related to: quasarframework/quasar-ui-qcalendar#378

This is the output of quasar info:

Operating System - Darwin(23.0.0) - darwin/arm64
NodeJs - 20.7.0

Global packages
  NPM - 10.1.0
  yarn - 1.22.19
  @quasar/cli - 2.2.3
  @quasar/icongenie - Not installed
  cordova - Not installed

Important local packages
  quasar - 2.12.7 -- Build high-performance VueJS user interfaces (SPA, PWA, SSR, Mobile and Desktop) in record time
  @quasar/app-webpack - 3.11.2 -- Quasar Framework App CLI with Webpack
  @quasar/extras - 1.16.7 -- Quasar Framework fonts, icons and animations
  eslint-plugin-quasar - Not installed
  vue - 3.3.4 -- The progressive JavaScript framework for building modern web UI.
  vue-router - 4.2.5
  pinia - 2.1.6 -- Intuitive, type safe and flexible Store for Vue
  vuex - Not installed
  electron - Not installed
  electron-packager - Not installed
  electron-builder - Not installed
  @babel/core - 7.23.0 -- Babel compiler core.
  webpack - 5.88.2 -- Packs ECMAScript/CommonJs/AMD modules for the browser. Allows you to split your codebase into multiple bundles, which can be loaded on demand. Supports loaders to preprocess files, i.e. json, jsx, es7, css, less, ... and your custom stuff.
  webpack-dev-server - 4.11.1 -- Serves a webpack app. Updates the browser on changes.
  workbox-webpack-plugin - Not installed
  register-service-worker - 1.7.2 -- Script for registering service worker, with hooks
  typescript - 4.9.4 -- TypeScript is a language for application scale JavaScript development
  @capacitor/core - Not installed
  @capacitor/cli - Not installed
  @capacitor/android - Not installed
  @capacitor/ios - Not installed

Quasar App Extensions
  @quasar/quasar-app-extension-qpdfviewer - 2.0.0-alpha.6 -- QPdfviewer is an app extension for viewing PDF files
  @quasar/quasar-app-extension-testing-e2e-cypress - 5.1.1 -- A Quasar App Extension for Cypress e2e
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

No branches or pull requests

1 participant