小编use*_*167的帖子

将 Storybook 迁移到 6.4 错误:webpack < 5 默认情况下用于包含 Node.js 核心模块的 Polyfill

在将故事书迁移到最新版本时,我一直在遵循多个指南和在线故障排除。我收到此错误:

BREAKING CHANGE: webpack < 5 used to include polyfills for node.js core modules by default.
This is no longer the case. Verify if you need this module and configure a polyfill for it.

If you want to include a polyfill, you need to:
        - add a fallback 'resolve.fallback: { "path": require.resolve("path-browserify") }'
        - install 'path-browserify'
If you don't want to include a polyfill, you can use an empty module like this:
        resolve.fallback: { "path": false }
resolve 'path' in …
Run Code Online (Sandbox Code Playgroud)

storybook angular-storybook

8
推荐指数
0
解决办法
1600
查看次数

为什么ALSA lib在Ubuntu中无法使用?

我正在使用portaudio编写程序,但是一旦运行它,我就会遇到这些问题(该程序可以编译并运行,但是我怀疑由于这些问题,它的行为不正常。)任何想法如何解决该问题?

ALSA lib pcm_dsnoop.c:618:(snd_pcm_dsnoop_open) unable to open slave
ALSA lib pcm_dmix.c:1022:(snd_pcm_dmix_open) unable to open slave
ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.rear
ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.center_lfe
ALSA lib pcm.c:2239:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.side
bt_audio_service_open: connect() failed: Connection refused (111)
bt_audio_service_open: connect() failed: Connection refused (111)
bt_audio_service_open: connect() failed: Connection refused (111) 
bt_audio_service_open: connect() failed: Connection refused (111)
ALSA lib pcm_dmix.c:1022:(snd_pcm_dmix_open) unable to open slave
Cannot connect to server socket err = No such file or directory
Cannot connect …
Run Code Online (Sandbox Code Playgroud)

alsa ubuntu-14.04 ubuntu-16.04

5
推荐指数
0
解决办法
2163
查看次数

Angular 表单:复杂嵌套反应表单和根组件验证的最佳实践

几天来,我一直在努力为我的用例找到一个好的模式。我有一个非常复杂的反应式表单,充满了嵌套组件,一些字段是必需的,某些字段可能会在特定条件下出现,等等……这给维护代码带来了巨大的问题。到目前为止,我使用的方法是将 formControl 传递给子组件并从那里填充,但是鉴于表单的大小,事情开始变得非常难以调试。此表单必须在提交整个表单时,对所有嵌套字段进行验证,并标记任何需要但尚未插入的字段。我一直在探索 2 种方法,但 2 种方法似乎都没有任何帮助:

  • Control Value Accessor:概念很完美,逻辑在子级之间完美分割,父级不必关心它,但缺点是子级控制器没有暴露,我不能把所有子窗体都标记为AsTouch来显示各自的错误
  • 控件容器:这种方法似乎需要在父级定义所有控件,但作为一个非常大的形式,它似乎真的适得其反,并没有真正解决我的问题。

我想知道是否有人对此类表格有任何经验,并能够就这种情况下的最佳做法提供一些指导。我使用 Control Container 做了一个非常简单的 stackblitz,只有一个子孩子,不幸的是我无法让它运行https://stackblitz.com/edit/angular-ivy-axbgr5

angular formgroups

5
推荐指数
2
解决办法
1728
查看次数

liquibase.integration.spring.SpringLiquibase 可从 spring boot 中的 2 个位置错误

我正在尝试将 Spring Boot 与 liquibase 集成,但是当我运行该应用程序时,它会引发以下错误:

An attempt was made to call the method liquibase.integration.spring.SpringLiquibase.setLiquibaseSchema(Ljava/lang/String;)V but it does not exist. Its class, liquibase.integration.spring.SpringLiquibase, is available from the following locations:

    jar:file:/C:/Users/Dev/.gradle/caches/modules-2/files-2.1/org.liquibase/liquibase-core/3.5.5/c65051f327382018bd09c30380f25eac96f210da/liquibase-core-3.5.5.jar!/liquibase/integration/spring/SpringLiquibase.class

It was loaded from the following location:

    file:/C:/Users/Dev/.gradle/caches/modules-2/files-2.1/org.liquibase/liquibase-core/3.5.5/c65051f327382018bd09c30380f25eac96f210da/liquibase-core-3.5.5.jar


Action:

Correct the classpath of your application so that it contains a single, compatible version of liquibase.integration.spring.SpringLiquibase
Run Code Online (Sandbox Code Playgroud)

看起来问题是由 spring-boot-starter-data-jpa 给出的,一旦我删除了依赖项,应用程序就可以正常运行。这是我的完整依赖项列表,但我还需要 JPA 来编写我的持久性类。

dependencies {
        compile('org.springframework.boot:spring-boot-starter-actuator')
        compile 'org.springframework.boot:spring-boot-starter-web'

        runtime('org.postgresql:postgresql:42.2.5')

        compile 'org.webjars:bootstrap:4.1.3'
        compile 'org.webjars:webjars-locator-core'

        compile("org.springframework.boot:spring-boot-starter-data-jpa")
        compile("org.hibernate:hibernate-entitymanager:4.3.4.Final")
        compile("org.hibernate:hibernate-validator:6.0.16.Final")
        compile ("org.hibernate:hibernate-core:5.4.1.Final")

        testCompile 'org.springframework.boot:spring-boot-starter-test'

        compile("org.liquibase:liquibase-core:3.5.5")

        liquibaseRuntime 'org.liquibase:liquibase-gradle-plugin:2.0.1' …
Run Code Online (Sandbox Code Playgroud)

liquibase spring-data-jpa build.gradle spring-boot

3
推荐指数
1
解决办法
5448
查看次数