By continuing you indicate that you have read and agree to our Terms of service and Privacy policy
By continuing you indicate that you have read and agree to our Terms of service and Privacy policy
Popular Releases
Popular Libraries
New Libraries
Top Authors
Trending Kits
Trending Discussions
Learning
Explore Related Topics
terminal | Windows Terminal Preview v1.13.1098 |
thefuck | |
rust | Rust 1.60.0 |
webpack | |
reveal.js | 4.3.0 |
terminal Windows Terminal Preview v1.13.1098 |
thefuck |
rust Rust 1.60.0 |
webpack |
reveal.js 4.3.0 |
by ohmyzsh shell
141698 MIT
🙃 A delightful community-driven (with 2,000+ contributors) framework for managing your zsh configuration. Includes 300+ optional plugins (rails, git, macOS, hub, docker, homebrew, node, php, python, etc), 140+ themes to spice up your morning, and an auto-update tool so that makes it easy to keep up with the latest updates from the community.
by jackfrued python
114192
Python - 100天从新手到大师
by microsoft c++
82454 MIT
The new Windows Terminal and the original Windows console host, all in the same place!
by nvbn python
65678 MIT
Magnificent app which corrects your previous console command.
by rust-lang rust
65482 NOASSERTION
Empowering everyone to build reliable and efficient software.
by django python
63447 NOASSERTION
The Web framework for perfectionists with deadlines.
by webpack javascript
60899 MIT
A bundler for javascript and friends. Packs many modules into a few bundled assets. Code Splitting allows for loading parts of the application on demand. Through "loaders", modules can be CommonJs, AMD, ES6 modules, CSS, Images, JSON, Coffeescript, LESS, ... and your custom stuff.
by hakimel javascript
58580 MIT
The HTML Presentation Framework
by adam-p javascript
54089 MIT
Google Chrome, Firefox, and Thunderbird extension that lets you write email in Markdown and render it before sending.
by ohmyzsh shell
141698 MIT
🙃 A delightful community-driven (with 2,000+ contributors) framework for managing your zsh configuration. Includes 300+ optional plugins (rails, git, macOS, hub, docker, homebrew, node, php, python, etc), 140+ themes to spice up your morning, and an auto-update tool so that makes it easy to keep up with the latest updates from the community.
by jackfrued python
114192
Python - 100天从新手到大师
by microsoft c++
82454 MIT
The new Windows Terminal and the original Windows console host, all in the same place!
by nvbn python
65678 MIT
Magnificent app which corrects your previous console command.
by rust-lang rust
65482 NOASSERTION
Empowering everyone to build reliable and efficient software.
by django python
63447 NOASSERTION
The Web framework for perfectionists with deadlines.
by webpack javascript
60899 MIT
A bundler for javascript and friends. Packs many modules into a few bundled assets. Code Splitting allows for loading parts of the application on demand. Through "loaders", modules can be CommonJs, AMD, ES6 modules, CSS, Images, JSON, Coffeescript, LESS, ... and your custom stuff.
by hakimel javascript
58580 MIT
The HTML Presentation Framework
by adam-p javascript
54089 MIT
Google Chrome, Firefox, and Thunderbird extension that lets you write email in Markdown and render it before sending.
by slidevjs typescript
19954 MIT
Presentation Slides for Developers (Beta)
by qier222 javascript
14385 MIT
高颜值的第三方网易云播放器,支持 Windows / macOS / Linux :electron:
by WerWolv c++
12561 GPL-2.0
🔍 A Hex Editor for Reverse Engineers, Programmers and people who value their retinas when working at 3 AM.
by foambubble typescript
11783 NOASSERTION
A personal knowledge management and sharing system for VSCode
by mxrch python
10124 MPL-2.0
🕵️♂️ Investigate Google emails and documents.
by charmbracelet go
9726 MIT
A powerful little TUI framework 🏗
by aristocratos shell
9013 Apache-2.0
Linux/OSX/FreeBSD resource monitor
by JetBrains kotlin
8605 Apache-2.0
Compose Multiplatform, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
by muesli go
8271 NOASSERTION
Disk Usage/Free Utility - a better 'df' alternative
by slidevjs typescript
19954 MIT
Presentation Slides for Developers (Beta)
by qier222 javascript
14385 MIT
高颜值的第三方网易云播放器,支持 Windows / macOS / Linux :electron:
by WerWolv c++
12561 GPL-2.0
🔍 A Hex Editor for Reverse Engineers, Programmers and people who value their retinas when working at 3 AM.
by foambubble typescript
11783 NOASSERTION
A personal knowledge management and sharing system for VSCode
by mxrch python
10124 MPL-2.0
🕵️♂️ Investigate Google emails and documents.
by charmbracelet go
9726 MIT
A powerful little TUI framework 🏗
by aristocratos shell
9013 Apache-2.0
Linux/OSX/FreeBSD resource monitor
by JetBrains kotlin
8605 Apache-2.0
Compose Multiplatform, a modern UI framework for Kotlin that makes building performant and beautiful user interfaces easy and enjoyable.
by muesli go
8271 NOASSERTION
Disk Usage/Free Utility - a better 'df' alternative
1
244 Libraries
79940
2
227 Libraries
845
3
221 Libraries
113960
4
196 Libraries
11042
5
144 Libraries
154572
6
99 Libraries
17085
7
94 Libraries
5905
8
84 Libraries
11441
9
83 Libraries
1306
10
81 Libraries
11581
Data Summary :
Resources that have been shared for the problem statement has info about food items and their description. Also we had order info from both donor and from consumer side orders on daily basis. We have done data cleaning and preprocessing as required.
Recommendation system :
In order to control the food wastage we have built Recommendation engine using "item-item based collaborative filtering" to recommend the items which expire early and are more in consumption.
Data Analysis :
We have developed a dashboard on tableau using cleaned datasets and these analysis can be used to match supply-demand of different types of food and to give an overview to the NGO, donors and consumers on how to reduce the food wastage.
Use the open source, cloud APIs, or public libraries listed below in your application development based on your technology preferences, such as primary language. The below list also provides a view of the components' rating on different dimensions such as community support availability, security vulnerability, and overall quality, helping you make an informed choice for implementation and maintenance of your application. Please review the components carefully, having a no license alert or proprietary license, and use them appropriately in your applications. Please check the component page for the exact license of the component. You can also get information on the component's features, installation steps, top code snippets, and top community discussions on the component details page. The links to package managers are listed for download, where packages are readily available. Otherwise, build from the respective repositories for use in your application. You can also use the source code from the repositories in your applications based on the respective license types. analysis machine learning
Build interactive applications with 2D and 3D animations, animated elements, elegant UI effects, immersive experiences, data visualization, and more using Python animation libraries. Python animation libraries are extremely useful in creating elaborate and graphical data visualization through a variety of animations such as Linear Graphs, Bar Plot Races, Scatter Plots, Horizontal and Vertical Movements in Bar Charts, Brownian Motion, Dynamic Axes, and more. It’s important to note that Python itself cannot create animation. Therefore, an external animation framework or library needs to be integrated into the program to pass a sequence of image frames and create a movement effect, i.e., animation. Check out the below list to find the trending Python animation libraries for your data visualization applications: Matplotlib animation library is the most popular one for plotting and data visualization in Python. It is used for creating 2-D plotting that can be embedded directly into applications. The Plotly library provides more than 40 unique chart types for creating web-based data visualizations that can be displayed in Jupyter notebooks or web applications. Based on Matplotlib, the Seaborn library offers a wide range of dataset-oriented plotting and visualization functions for creating attractive statistical graphics in Python.
SPEAKER COUNTING
It enhances understanding through automatic speech recognition
Beneficial for real - world applications like call-center transcription and meeting transcription analytics
Speaker Diarization is a developing field of study, with new approaches being published on a frequent basis.
The Problem
Not many studies have been done for estimating a large number of speakers.
Diarization becomes extremely difficult when the number of speakers is huge.
Providing the number of speakers to the diarization system can be advantageous
Complete solution Architecture -
Machine Learning model - To predict the no. of speakers and the time stamps of the speaker.
Web App - Frontend for the user to use the feature.
Middleware Flask Api - To connect Frontend and ML Model.
We have build a Web App that a user can use to communicate and leverage the advantages of the our Machine learning model. Since the model we build and the web app are build on different platforms, we used REST API as a middleware to connect frontend and model.
ML Model Solution Process These are used to create our Web UI using node as backend and VueJs as front end.
1. Preprocessing: Denoising -> Speech separation
2. Embedding Extraction: YAMNet sound & classification model
3. Speaker Counting: Machine learning model selection -> Model training -> Model prediction
Data Preprocessing Technologies used for pre processing the audio data. Audio Pre Processing The additional libaries are use to processing the audio which are needed to be fed into the classifier model. Model Trainning This libaries are used to create the two classifier models which are then both combined into one.
Regex libraries are essential for searching text, validating input in forms, or modifying wildcards to produce more specific and accurate search results. Using regex, you can parse out email addresses, URLs, phone numbers, or any other specific phrase from a larger document of text. Regex libraries were designed for this kind of search and extraction, serving as both a tool and a language understood by most software applications. Regex libraries are the most efficient and reliable way to parse text. They can be used to search, edit, and delete data with extreme precision. Regex libraries come in handy while working on text-based data such as documents, emails, scripts, etc. These libraries use regular expressions to parse text and filter out useful information from it. In this kit, we will be looking at some of the best Python regex libraries.
Open Source Intelligence has played a pivotal role in key events like tracing Covid-19 origins, MH17 downing, the Boston Marathon bombing, and the Myanmar refugee crisis. Approximately 500 million tweets are published every day, totaling over 200 billion posts in a year. Facebook users upload 350 million photos per day. YouTube users add nearly 720,000 hours of new video every day. Almost all devices are online today in the connected world. OSINT Framework The OSINT framework enables gathering information from free tools or resources. The below open source libraries introduce and enable gathering information based on the OSINT Framework. Target Reconnaissance Recon-ng is a full-featured reconnaissance framework designed with the goal of providing a powerful environment to conduct open source web-based reconnaissance quickly and thoroughly. Information Collection theHarvester and similar tools gather emails, names, subdomains, IPs and URLs using multiple public data sources. Track Online Assets Shodan and Amass enable researchers to see the exposed assets. Google Search Google dorks provides information through the usage of operators, which are otherwise difficult to extract using simple searches.
While monitoring messages was exclusive to intelligence agencies, the tons of information available in the public realm today has made it possible for general and security enthusiasts to look for insights that might not have been possible earlier. The U.S. Department of State defines OSINT as "intelligence that is produced from publicly available information and is collected, exploited, and disseminated promptly to an appropriate audience to address a specific intelligence requirement."
Designed correctly, OSINT can reduce risk across a variety of common risks such as weather conditions, disease outbreaks, corporate risk management, data privacy, reputation management, in addition to higher-order tasks like national security and cybersecurity. Do not construe this as legal advice, promotion, or authorization to indulge in any activity whatsoever.
Tetris has established itself as a famous game since the early video games. Even though the game looks simple requires intelligence and skills to play. The gameplay consists of tiles or tetrominoes of different shapes and a game field grid. The game's objective is to position the tiles in the game field, which fills the grid. The disappearing line will grant points. Accumulated points help users to move a level up. Once the game is over, the final score will be displayed to the user.
Following steps to be followed to build your own Tetris game,
1.Create Blocks for Tetris
2.Graphic designs
3.Multi-player Tetris
4.Creating customized Game field
5.2D Tetris
6.3D Tetris
7.Control keys Create Blocks & Graphics Listed below libraries help in creating the best graphic design for gaming applications can help the moving tiles across the game field, selecting colors for tiles, making different shapes of tiles using different sizes of arrays, and matrix rotation. In the case of a single-player game, the game gets over when all blocks are formed such that no lines are disappearing. 2D Tetris Game 2D games are titles with only two axes of motion. Typically, these are "flat" games where you can move left and right up and down. You can create a 2D Tetris game using the below libraries. 3D Tetris Game Players control multiple falling blocks, positioning and rotating them to clear layers in a three-dimensional environment similar to Tetris gameplay. You can create a 3D Tetris game using the below libraries. Creating own Game field The libraries listed below help to create custom matrices for the Tetris game. Multi-player Tetris Listed below libraries helps to build a multi-player Tetris game, two players will play on their game field one who gets more scores will win the battle. Control Keys Key mapper is an open-source that allows users to use a key or combination of keys to perform a rotation and move, which can be used for navigating. You can create your keys to play using the below libraries.
According to ISO data, 249 countries are operating at different time zones in the world today. Each country has its people, culture, heritage, language, etc. The digital world distinguishes people based on their country of origin for distinct reasons. A time zone is a region with a standard time. There are over 24 different Time zones for the world. Working with the Time zone and country is highly critical in this digital era. Getting User Time zone using JavaScript Time zone data is essential in sending, storing, receiving, and displaying them to the users. If your application needs to show time zone-specific events or data to a user, you will need to retrieve the Time zone from where the application has been used or browsed. Some of the libraries that help you detect time zones are below. Getting User Country using JavaScript When a country's specific information is needed for users, you must detect the application's country. To achieve this, you need to catch each request's country of origin and show data or recommendations based on that. Some of the libraries used to detect user country are below.
this is related to UI Test tools. Gr1 this is GR1
.NET is a well-established programming language. It has hundreds of libraries across several platforms. And developers have used them for many years. Following are the key features of Build tools, Big Builds: A collection of tasks and targets for MSBuild that improve build performance in a number of ways. Code Analysis: Contains the MSBuild targets and tasks necessary to run code analysis on your projects outside of Visual Studio. Compute Clusters: Provides a set of MSBuild tasks that can be used to execute jobs across multiple machines in a compute cluster. FSM (Finite State Machine): A scalable, extensible state machine implementation for C
Continuous integration and deployment is the practice of automating the build, test, and deployment of applications. Find the currated C# libraries to enable optimized build tools and process in your application. Full list of the best open source C# Build Tools libraries below.
Audio Analysis from team Triple_trouble Group Name 1 Group Name 2 Group Name 3 Group Name 4 Group Name 5
A Dictionary is used to find the meaning of the word. You can also use a dictionary to check the spelling of the particular word. Use the following libraries for creating your own Dictionary App with open-Source libraries.
Generally, people store information in files to track them easily on their need, and this basis file management system has been a great pillar to track, manage, and keep their data. File Management System is also used to send and receive our data and information in their necessity. File Management System also provides security to our files and also prevents them from destroying in future use. Use the following curated libraries to develop your own file management system.
This is Stella, an AI chatbot that runs on a web browser and capable of maintaining conversations with humans and also handle to-do lists. This project is for the HackMakers hackathon.
- from Team Stellars. development environment VSCode and Jupyter Notebook are used for development and debugging. Jupyter Notebook is a web based interactive environment often used for experiments, whereas VSCode is used to get a typical experience of IDE for developers. Exploratory Data Analysis For extensive analysis and exploration of data, and to deal with arrays, these libraries are used. They are also used for performing scientific computation and data manipulation. Text mining Libraries in this group are used for analysis and processing of unstructured natural language. The data, as in its original form aren't used as it has to go through processing pipeline to become suitable for applying machine learning techniques and algorithms. Machine Learning We used to following libraries to train our model. Request servicing via REST API Web frameworks help build serving solution as REST APIs. The resources involved for servicing request can be handled by containerising and hosting on hyperscalers.
In this solution we are going to add colors to the text with help of termcolor of C++ library for printing colored messages to the terminal .python has many libraries which provide the ability to work with Texts. In this solution kit, I am sharing the code snippet and library that I use to color the text in Python which can be executed directly in the IDE. Preview of the output that you will get on running this code in your IDE In this solution we have used Termcolor from python I hope you found this useful i have added the Dependent libraries , versions in the following sections. I have searched using "How to add colors to printed text " in Kandi. you can try any use case If you don't have this termcolor and colorama Library that required to run this code. You can install by clicking the above link and copying the pip install command from the termcolor page in Kandi. You can search any Library Like termcolor and colorama in kandi I have tested this solution with following versions. Be mindful of changes when working with other versions Using this solution we able to color the text with termcolor Library in python with simple steps. This process also facilities an easy to use, hassle free method to create a hands-on working version of code which would help us color the text in Python.Code
Dependent Library
Environment Test
Support
In this solution we are going to Adding color to the text in our code. python has many libraries which provide the ability to work with Texts. Colorama is a famous and prominent Library used in Python with the help of Colorama we are going to color text. Colorama Library also helps to change the style ,color, Brightness ,background of the text . In this solution kit, I am sharing the code snippet and library that I use to color the text in Python which can be executed directly in the IDE Preview of the output that you will get on running this code in your IDE In this solution we have used Colorama library from python I hope you found this useful i have added the Dependent libraries , versions in the following sections I have searched using "Add text Color while print" in Kandi. you can try any use case If you don't have this colorama and termcolor Library that required to run this code. You can install by clicking the above link and copying the pip install command from the Colorama page in Kandi. You can search any Library Like colorama and termcolor in kandi I have tested this solution with following versions. Be mindful of changes when working with other versions Using this solution we able to change the style , color, Brightness of the Text in Terminal using Colorama Library in python with simple steps. This process also facilities an easy to use, hassle free method to create a hands-on working version of code which would help us color the text in Python.Code
Dependent Library
Environment Test
Support
Java has many libraries which provide the ability to work with CSV files. This solution gives a hassle-free ready to go code template to read json list using JSONArray in Java which can be executed straight in the IDE. Add required dependent library in your Gradle or Maven files and we suggest you to use the same versions of libraries which we used. Fig 1: Preview of the output that you will get on running this code from your IDE I hope you found this useful. I have added the link to dependent libraries, version information in the following sections. I found this code snippet by searching for 'json array list to csv format' in kandi. You can try any such use case! I tested this solution in the following versions. Be mindful of changes when working with other versions. Using this solution, we are able to convert an json array to csv with simple steps. This process also facilities an easy way to use, hassle-free method to create a hands-on working version of code which would help us to convert an json array to csv. You can add the dependent library in your gradle or maven files. you can get the dependancy xml in above link You can search for any dependent library on kandi like apache commons io and json javaCode
Instructions
Environment Tested
Dependent Libraries
Support
The technique for converting a JSON array to a CSV file using Apache Commons IO in Java can be helpful in several situations where you want to export data stored in a JSON array to a CSV file. This may be helpful in the following cases, for instance: It offers a large selection of classes and methods that can be utilized to carry out different I/O-related operations, including reading and writing files, navigating directories and files, reading and writing to input and output streams, and more. When working with I/O operations in Java, Apache Commons IO is a valuable tool in your toolbox because it is a widely used library. Here is an example of how you can convert JSON array to CSV using Apache common-io in Java for your application: Fig 1: Preview of the output that you will get on running this code from your IDE I hope you found this useful. I have added the link to dependent libraries, version information in the following sections. I found this code snippet by searching for "json array to csv in java" in kandi. You can try any such use case! You can add the dependent library in your gradle or maven files. you can get the dependancy xml in above link You can search for any dependent library on kandi like apache commons io and json java
Code
Development Libraries
Support
This kit contains libraries (modules in python) that can be used to set up a Live Django Web Server with Facial Recognition Features. Server Setup Online Django Server Setup can be done using these modules of python Face Recognition These modules of python help in using the Face Recognition feature
Image Manipulation and Handling Following Libraries help in image manipulation and handling images in the back-end Files Serving Following Libraries help in hosting files with the Django Server
OpenCV is a computer vision library written in C++ and widely used for image and video processing. It offers a range of features for working with photographs and movies, including the ability to load and save images, use filters, find edges, and find and track objects. In collaboration, applications involving image and video processing are frequently created using Python and OpenCV. This combination enables you to develop solid and adaptable programs that can address various computer vision issues. In our work as developers, we frequently must read and rotate the photos in our applications to complete various image processing activities, such as recognition, upload, augmentation, training, and many more. There are numerous libraries for Python that enable working with images. Python has features for manipulating, enhancing, and creating more images. In addition to using additional OpenCV functions to apply other transformations to the image, such as scaling, cropping, and applying filters, you can modify the angle of rotation and the image's size to get the desired effect. Here is an example of how we can draw a line beyond the second point using opencv Preview of the output that you will get on running this code from your IDE CODE In this solution we use the numpy and open cv library I hope you found this useful. I have added the link to dependent libraries, version information in the following sections. ifound this code snippet by searching for "Draw a line in open cv and python beyond given points" in kandi. You can try any such use case! If you do not have OpenCV and numpy that is required to run this code, you can install it by clicking on the above link and copying the pip Install command from the OpenCV page in kandi. You can search for any dependent library on kandi like OpenCV and numpy I tested this solution in the following versions. Be mindful of changes when working with other versions Using this solution, we are going to draw a line beyond the second given point using the OpenCv library and numpy library in Python with simple steps. This process also facilities an easy to use, hassle free method to create a hands-on working version of code which would help us draw a image in Python
Dependent Library
Environment Test
Support
Graphics in C++ is to develop a graphic model to draw curves, lines of different colors and styles, phrases with fashionable fonts with different typefaces, colors, and sizes, and geometrical shapes like circles, rectangles, etc. Graphics programming could help us to create projects, games, animation, and more. There are two different modes in C++ by default- text mode and graphics mode. To implement the graphics, which are a two-dimensional notion, we need to use C++ programming and a few functions. The prerequisites of a graphics monitor are a graphics card like a VGA, SVGA, or EGA. Importing the "graphics.h" library into the GCC compiler enables the production of graphics in the C++ console. C++ is used to program graphics via the terminal or command prompt or the other method you need to install the DevC++ compiler. In this mode, the output is shown as points or pixels on the computer screen. The screen is divided into tiny dots called pixels in graphics mode. For instance, the screen on a VGA display is divided into 480 rows and 640 columns of dots. The term "resolution screen" refers to the number of dots per inch. The clarity of the graphics increases with the number of pixels. The circle, line, eclipse, and other geometric forms are also traceable. The primary technique adopted is object-oriented programming. Since C++ relies on low-level programs, there are no built-in drawing methods, and APIs are used to create visuals. C++ is frequently regarded as one of the leading programming languages for computer graphics. To operate in graphics, the C++ compiler requires. - the "graphics.h" header file that includes built-in graphic features - files for the Borland Graphics Interface (BGI) that has the graphics driver programs to set up the computer monitor to display graphics, and - the "chr" extension files for the character font style. The wide adoption of C++ by the developers of IDEs, editors, compilers, test frameworks, and other tools makes it easier to use. The best libraries are magnum, OpenSceneGraph, AtomicGameEngine, Vulkan, glbinding, LibVT, Cell, minigrafx, tinyrenderer, ripes, etc. Check out the list below to find more popular C++ 2D Graphics libraries for your applications:
Data Summary :
Resources that have been shared for the problem statement has info about food items and their description. Also we had order info from both donor and from consumer side orders on daily basis. We have done data cleaning and preprocessing as required.
Recommendation system :
In order to control the food wastage we have built Recommendation engine using "item-item based collaborative filtering" to recommend the items which expire early and are more in consumption.
Data Analysis :
We have developed a dashboard on tableau using cleaned datasets and these analysis can be used to match supply-demand of different types of food and to give an overview to the NGO, donors and consumers on how to reduce the food wastage.
Use the open source, cloud APIs, or public libraries listed below in your application development based on your technology preferences, such as primary language. The below list also provides a view of the components' rating on different dimensions such as community support availability, security vulnerability, and overall quality, helping you make an informed choice for implementation and maintenance of your application. Please review the components carefully, having a no license alert or proprietary license, and use them appropriately in your applications. Please check the component page for the exact license of the component. You can also get information on the component's features, installation steps, top code snippets, and top community discussions on the component details page. The links to package managers are listed for download, where packages are readily available. Otherwise, build from the respective repositories for use in your application. You can also use the source code from the repositories in your applications based on the respective license types. analysis machine learning
Build interactive applications with 2D and 3D animations, animated elements, elegant UI effects, immersive experiences, data visualization, and more using Python animation libraries. Python animation libraries are extremely useful in creating elaborate and graphical data visualization through a variety of animations such as Linear Graphs, Bar Plot Races, Scatter Plots, Horizontal and Vertical Movements in Bar Charts, Brownian Motion, Dynamic Axes, and more. It’s important to note that Python itself cannot create animation. Therefore, an external animation framework or library needs to be integrated into the program to pass a sequence of image frames and create a movement effect, i.e., animation. Check out the below list to find the trending Python animation libraries for your data visualization applications: Matplotlib animation library is the most popular one for plotting and data visualization in Python. It is used for creating 2-D plotting that can be embedded directly into applications. The Plotly library provides more than 40 unique chart types for creating web-based data visualizations that can be displayed in Jupyter notebooks or web applications. Based on Matplotlib, the Seaborn library offers a wide range of dataset-oriented plotting and visualization functions for creating attractive statistical graphics in Python.
SPEAKER COUNTING
It enhances understanding through automatic speech recognition
Beneficial for real - world applications like call-center transcription and meeting transcription analytics
Speaker Diarization is a developing field of study, with new approaches being published on a frequent basis.
The Problem
Not many studies have been done for estimating a large number of speakers.
Diarization becomes extremely difficult when the number of speakers is huge.
Providing the number of speakers to the diarization system can be advantageous
Complete solution Architecture -
Machine Learning model - To predict the no. of speakers and the time stamps of the speaker.
Web App - Frontend for the user to use the feature.
Middleware Flask Api - To connect Frontend and ML Model.
We have build a Web App that a user can use to communicate and leverage the advantages of the our Machine learning model. Since the model we build and the web app are build on different platforms, we used REST API as a middleware to connect frontend and model.
ML Model Solution Process These are used to create our Web UI using node as backend and VueJs as front end.
1. Preprocessing: Denoising -> Speech separation
2. Embedding Extraction: YAMNet sound & classification model
3. Speaker Counting: Machine learning model selection -> Model training -> Model prediction
Data Preprocessing Technologies used for pre processing the audio data. Audio Pre Processing The additional libaries are use to processing the audio which are needed to be fed into the classifier model. Model Trainning This libaries are used to create the two classifier models which are then both combined into one.
Regex libraries are essential for searching text, validating input in forms, or modifying wildcards to produce more specific and accurate search results. Using regex, you can parse out email addresses, URLs, phone numbers, or any other specific phrase from a larger document of text. Regex libraries were designed for this kind of search and extraction, serving as both a tool and a language understood by most software applications. Regex libraries are the most efficient and reliable way to parse text. They can be used to search, edit, and delete data with extreme precision. Regex libraries come in handy while working on text-based data such as documents, emails, scripts, etc. These libraries use regular expressions to parse text and filter out useful information from it. In this kit, we will be looking at some of the best Python regex libraries.
Open Source Intelligence has played a pivotal role in key events like tracing Covid-19 origins, MH17 downing, the Boston Marathon bombing, and the Myanmar refugee crisis. Approximately 500 million tweets are published every day, totaling over 200 billion posts in a year. Facebook users upload 350 million photos per day. YouTube users add nearly 720,000 hours of new video every day. Almost all devices are online today in the connected world. OSINT Framework The OSINT framework enables gathering information from free tools or resources. The below open source libraries introduce and enable gathering information based on the OSINT Framework. Target Reconnaissance Recon-ng is a full-featured reconnaissance framework designed with the goal of providing a powerful environment to conduct open source web-based reconnaissance quickly and thoroughly. Information Collection theHarvester and similar tools gather emails, names, subdomains, IPs and URLs using multiple public data sources. Track Online Assets Shodan and Amass enable researchers to see the exposed assets. Google Search Google dorks provides information through the usage of operators, which are otherwise difficult to extract using simple searches.
While monitoring messages was exclusive to intelligence agencies, the tons of information available in the public realm today has made it possible for general and security enthusiasts to look for insights that might not have been possible earlier. The U.S. Department of State defines OSINT as "intelligence that is produced from publicly available information and is collected, exploited, and disseminated promptly to an appropriate audience to address a specific intelligence requirement."
Designed correctly, OSINT can reduce risk across a variety of common risks such as weather conditions, disease outbreaks, corporate risk management, data privacy, reputation management, in addition to higher-order tasks like national security and cybersecurity. Do not construe this as legal advice, promotion, or authorization to indulge in any activity whatsoever.
Tetris has established itself as a famous game since the early video games. Even though the game looks simple requires intelligence and skills to play. The gameplay consists of tiles or tetrominoes of different shapes and a game field grid. The game's objective is to position the tiles in the game field, which fills the grid. The disappearing line will grant points. Accumulated points help users to move a level up. Once the game is over, the final score will be displayed to the user.
Following steps to be followed to build your own Tetris game,
1.Create Blocks for Tetris
2.Graphic designs
3.Multi-player Tetris
4.Creating customized Game field
5.2D Tetris
6.3D Tetris
7.Control keys Create Blocks & Graphics Listed below libraries help in creating the best graphic design for gaming applications can help the moving tiles across the game field, selecting colors for tiles, making different shapes of tiles using different sizes of arrays, and matrix rotation. In the case of a single-player game, the game gets over when all blocks are formed such that no lines are disappearing. 2D Tetris Game 2D games are titles with only two axes of motion. Typically, these are "flat" games where you can move left and right up and down. You can create a 2D Tetris game using the below libraries. 3D Tetris Game Players control multiple falling blocks, positioning and rotating them to clear layers in a three-dimensional environment similar to Tetris gameplay. You can create a 3D Tetris game using the below libraries. Creating own Game field The libraries listed below help to create custom matrices for the Tetris game. Multi-player Tetris Listed below libraries helps to build a multi-player Tetris game, two players will play on their game field one who gets more scores will win the battle. Control Keys Key mapper is an open-source that allows users to use a key or combination of keys to perform a rotation and move, which can be used for navigating. You can create your keys to play using the below libraries.
According to ISO data, 249 countries are operating at different time zones in the world today. Each country has its people, culture, heritage, language, etc. The digital world distinguishes people based on their country of origin for distinct reasons. A time zone is a region with a standard time. There are over 24 different Time zones for the world. Working with the Time zone and country is highly critical in this digital era. Getting User Time zone using JavaScript Time zone data is essential in sending, storing, receiving, and displaying them to the users. If your application needs to show time zone-specific events or data to a user, you will need to retrieve the Time zone from where the application has been used or browsed. Some of the libraries that help you detect time zones are below. Getting User Country using JavaScript When a country's specific information is needed for users, you must detect the application's country. To achieve this, you need to catch each request's country of origin and show data or recommendations based on that. Some of the libraries used to detect user country are below.
this is related to UI Test tools. Gr1 this is GR1
.NET is a well-established programming language. It has hundreds of libraries across several platforms. And developers have used them for many years. Following are the key features of Build tools, Big Builds: A collection of tasks and targets for MSBuild that improve build performance in a number of ways. Code Analysis: Contains the MSBuild targets and tasks necessary to run code analysis on your projects outside of Visual Studio. Compute Clusters: Provides a set of MSBuild tasks that can be used to execute jobs across multiple machines in a compute cluster. FSM (Finite State Machine): A scalable, extensible state machine implementation for C
Continuous integration and deployment is the practice of automating the build, test, and deployment of applications. Find the currated C# libraries to enable optimized build tools and process in your application. Full list of the best open source C# Build Tools libraries below.
Audio Analysis from team Triple_trouble Group Name 1 Group Name 2 Group Name 3 Group Name 4 Group Name 5
A Dictionary is used to find the meaning of the word. You can also use a dictionary to check the spelling of the particular word. Use the following libraries for creating your own Dictionary App with open-Source libraries.
Generally, people store information in files to track them easily on their need, and this basis file management system has been a great pillar to track, manage, and keep their data. File Management System is also used to send and receive our data and information in their necessity. File Management System also provides security to our files and also prevents them from destroying in future use. Use the following curated libraries to develop your own file management system.
This is Stella, an AI chatbot that runs on a web browser and capable of maintaining conversations with humans and also handle to-do lists. This project is for the HackMakers hackathon.
- from Team Stellars. development environment VSCode and Jupyter Notebook are used for development and debugging. Jupyter Notebook is a web based interactive environment often used for experiments, whereas VSCode is used to get a typical experience of IDE for developers. Exploratory Data Analysis For extensive analysis and exploration of data, and to deal with arrays, these libraries are used. They are also used for performing scientific computation and data manipulation. Text mining Libraries in this group are used for analysis and processing of unstructured natural language. The data, as in its original form aren't used as it has to go through processing pipeline to become suitable for applying machine learning techniques and algorithms. Machine Learning We used to following libraries to train our model. Request servicing via REST API Web frameworks help build serving solution as REST APIs. The resources involved for servicing request can be handled by containerising and hosting on hyperscalers.
In this solution we are going to add colors to the text with help of termcolor of C++ library for printing colored messages to the terminal .python has many libraries which provide the ability to work with Texts. In this solution kit, I am sharing the code snippet and library that I use to color the text in Python which can be executed directly in the IDE. Preview of the output that you will get on running this code in your IDE In this solution we have used Termcolor from python I hope you found this useful i have added the Dependent libraries , versions in the following sections. I have searched using "How to add colors to printed text " in Kandi. you can try any use case If you don't have this termcolor and colorama Library that required to run this code. You can install by clicking the above link and copying the pip install command from the termcolor page in Kandi. You can search any Library Like termcolor and colorama in kandi I have tested this solution with following versions. Be mindful of changes when working with other versions Using this solution we able to color the text with termcolor Library in python with simple steps. This process also facilities an easy to use, hassle free method to create a hands-on working version of code which would help us color the text in Python.Code
Dependent Library
Environment Test
Support
In this solution we are going to Adding color to the text in our code. python has many libraries which provide the ability to work with Texts. Colorama is a famous and prominent Library used in Python with the help of Colorama we are going to color text. Colorama Library also helps to change the style ,color, Brightness ,background of the text . In this solution kit, I am sharing the code snippet and library that I use to color the text in Python which can be executed directly in the IDE Preview of the output that you will get on running this code in your IDE In this solution we have used Colorama library from python I hope you found this useful i have added the Dependent libraries , versions in the following sections I have searched using "Add text Color while print" in Kandi. you can try any use case If you don't have this colorama and termcolor Library that required to run this code. You can install by clicking the above link and copying the pip install command from the Colorama page in Kandi. You can search any Library Like colorama and termcolor in kandi I have tested this solution with following versions. Be mindful of changes when working with other versions Using this solution we able to change the style , color, Brightness of the Text in Terminal using Colorama Library in python with simple steps. This process also facilities an easy to use, hassle free method to create a hands-on working version of code which would help us color the text in Python.Code
Dependent Library
Environment Test
Support
Java has many libraries which provide the ability to work with CSV files. This solution gives a hassle-free ready to go code template to read json list using JSONArray in Java which can be executed straight in the IDE. Add required dependent library in your Gradle or Maven files and we suggest you to use the same versions of libraries which we used. Fig 1: Preview of the output that you will get on running this code from your IDE I hope you found this useful. I have added the link to dependent libraries, version information in the following sections. I found this code snippet by searching for 'json array list to csv format' in kandi. You can try any such use case! I tested this solution in the following versions. Be mindful of changes when working with other versions. Using this solution, we are able to convert an json array to csv with simple steps. This process also facilities an easy way to use, hassle-free method to create a hands-on working version of code which would help us to convert an json array to csv. You can add the dependent library in your gradle or maven files. you can get the dependancy xml in above link You can search for any dependent library on kandi like apache commons io and json javaCode
Instructions
Environment Tested
Dependent Libraries
Support
The technique for converting a JSON array to a CSV file using Apache Commons IO in Java can be helpful in several situations where you want to export data stored in a JSON array to a CSV file. This may be helpful in the following cases, for instance: It offers a large selection of classes and methods that can be utilized to carry out different I/O-related operations, including reading and writing files, navigating directories and files, reading and writing to input and output streams, and more. When working with I/O operations in Java, Apache Commons IO is a valuable tool in your toolbox because it is a widely used library. Here is an example of how you can convert JSON array to CSV using Apache common-io in Java for your application: Fig 1: Preview of the output that you will get on running this code from your IDE I hope you found this useful. I have added the link to dependent libraries, version information in the following sections. I found this code snippet by searching for "json array to csv in java" in kandi. You can try any such use case! You can add the dependent library in your gradle or maven files. you can get the dependancy xml in above link You can search for any dependent library on kandi like apache commons io and json java
Code
Development Libraries
Support
This kit contains libraries (modules in python) that can be used to set up a Live Django Web Server with Facial Recognition Features. Server Setup Online Django Server Setup can be done using these modules of python Face Recognition These modules of python help in using the Face Recognition feature
Image Manipulation and Handling Following Libraries help in image manipulation and handling images in the back-end Files Serving Following Libraries help in hosting files with the Django Server
QUESTION
Getting the error "Nested CSS was detected, but CSS nesting has not been configured correctly" in React app?
Asked 2022-Mar-23 at 09:04I've been upgrading my CRA project to TailwindCSS 3, but now CSS nesting no longer works. Upon starting the server, the console spits out:
1(8:3) Nested CSS was detected, but CSS nesting has not been configured correctly.
2Please enable a CSS nesting plugin *before* Tailwind in your configuration.
3See how here: https://tailwindcss.com/docs/using-with-preprocessors#nesting
4
However, I don't see what must be done to correct this. I've tried setting up a plain CRA project with Tailwind (following this guide) just to make sure I have no conflicts, and still no success.
postcss.config.js:
1(8:3) Nested CSS was detected, but CSS nesting has not been configured correctly.
2Please enable a CSS nesting plugin *before* Tailwind in your configuration.
3See how here: https://tailwindcss.com/docs/using-with-preprocessors#nesting
4module.exports = {
5 plugins: {
6 "tailwindcss/nesting": {},
7 tailwindcss: {},
8 autoprefixer: {},
9 },
10};
11
As you can see, I have added the nesting plugin before Tailwind. It appears to me as if the plugin isn't being detected whatsoever. I've also tried replacing it with postcss-nesting
with same outcome.
Note: I've also tried using the array syntax with require('tailwind/nesting')
like the guide suggests.
Interestingly, removing all plugins from postcss.config.js (or using a require
that fails to resolve) still outputs the same error, implying that this file isn't needed to get Tailwind to load. Maybe I am missing something that causes the whole postcss.config.js file to not be loaded in the first place?
index.js:
1(8:3) Nested CSS was detected, but CSS nesting has not been configured correctly.
2Please enable a CSS nesting plugin *before* Tailwind in your configuration.
3See how here: https://tailwindcss.com/docs/using-with-preprocessors#nesting
4module.exports = {
5 plugins: {
6 "tailwindcss/nesting": {},
7 tailwindcss: {},
8 autoprefixer: {},
9 },
10};
11import React from "react";
12import ReactDOM from "react-dom";
13import "./index.css";
14
15ReactDOM.render(
16 <React.StrictMode>
17 <div className="a">
18 aaa
19 <div className="b">bbb</div>
20 </div>
21 </React.StrictMode>,
22 document.getElementById("root")
23);
24
index.css:
1(8:3) Nested CSS was detected, but CSS nesting has not been configured correctly.
2Please enable a CSS nesting plugin *before* Tailwind in your configuration.
3See how here: https://tailwindcss.com/docs/using-with-preprocessors#nesting
4module.exports = {
5 plugins: {
6 "tailwindcss/nesting": {},
7 tailwindcss: {},
8 autoprefixer: {},
9 },
10};
11import React from "react";
12import ReactDOM from "react-dom";
13import "./index.css";
14
15ReactDOM.render(
16 <React.StrictMode>
17 <div className="a">
18 aaa
19 <div className="b">bbb</div>
20 </div>
21 </React.StrictMode>,
22 document.getElementById("root")
23);
24@tailwind base;
25@tailwind components;
26@tailwind utilities;
27
28.a {
29 @apply text-blue-500;
30
31 .b {
32 @apply text-green-500;
33 }
34}
35
package.json: (omitted things for brevity)
1(8:3) Nested CSS was detected, but CSS nesting has not been configured correctly.
2Please enable a CSS nesting plugin *before* Tailwind in your configuration.
3See how here: https://tailwindcss.com/docs/using-with-preprocessors#nesting
4module.exports = {
5 plugins: {
6 "tailwindcss/nesting": {},
7 tailwindcss: {},
8 autoprefixer: {},
9 },
10};
11import React from "react";
12import ReactDOM from "react-dom";
13import "./index.css";
14
15ReactDOM.render(
16 <React.StrictMode>
17 <div className="a">
18 aaa
19 <div className="b">bbb</div>
20 </div>
21 </React.StrictMode>,
22 document.getElementById("root")
23);
24@tailwind base;
25@tailwind components;
26@tailwind utilities;
27
28.a {
29 @apply text-blue-500;
30
31 .b {
32 @apply text-green-500;
33 }
34}
35{
36 "name": "tailwindtest",
37 "dependencies": {
38 "react": "^17.0.2",
39 "react-dom": "^17.0.2",
40 "react-scripts": "5.0.0"
41 },
42 "scripts": {
43 "start": "react-scripts start",
44 "build": "react-scripts build",
45 "test": "react-scripts test",
46 "eject": "react-scripts eject"
47 },
48 "devDependencies": {
49 "autoprefixer": "^10.4.2",
50 "postcss": "^8.4.5",
51 "tailwindcss": "^3.0.12"
52 }
53}
54
ANSWER
Answered 2022-Feb-03 at 18:38This is mostly just bad news.
Create React App's Tailwind support means that they will detect tailwind.config.js
in the project and add tailwindcss
to their existing postcss
configuration. Source in CRA
The guide that Tailwind offers on their site creates a dummy postcss.config.js
- Making changes in this file does not change the actual postcss configuration. (misleading if anything)
This is a known issue currently - Github discussion on Tailwind support PR between Adam Wathan (Tailwind founder) and Ian Sutherland (CRA maintainer). But it does not seem like there is an intention to be fixed soon.
If you want to use nesting (or any PostCSS plugin really) is to eject from CRA using:
1(8:3) Nested CSS was detected, but CSS nesting has not been configured correctly.
2Please enable a CSS nesting plugin *before* Tailwind in your configuration.
3See how here: https://tailwindcss.com/docs/using-with-preprocessors#nesting
4module.exports = {
5 plugins: {
6 "tailwindcss/nesting": {},
7 tailwindcss: {},
8 autoprefixer: {},
9 },
10};
11import React from "react";
12import ReactDOM from "react-dom";
13import "./index.css";
14
15ReactDOM.render(
16 <React.StrictMode>
17 <div className="a">
18 aaa
19 <div className="b">bbb</div>
20 </div>
21 </React.StrictMode>,
22 document.getElementById("root")
23);
24@tailwind base;
25@tailwind components;
26@tailwind utilities;
27
28.a {
29 @apply text-blue-500;
30
31 .b {
32 @apply text-green-500;
33 }
34}
35{
36 "name": "tailwindtest",
37 "dependencies": {
38 "react": "^17.0.2",
39 "react-dom": "^17.0.2",
40 "react-scripts": "5.0.0"
41 },
42 "scripts": {
43 "start": "react-scripts start",
44 "build": "react-scripts build",
45 "test": "react-scripts test",
46 "eject": "react-scripts eject"
47 },
48 "devDependencies": {
49 "autoprefixer": "^10.4.2",
50 "postcss": "^8.4.5",
51 "tailwindcss": "^3.0.12"
52 }
53}
54npm run eject
55
After ejecting you can find CRA's postcss configuration in config/webpack.config.js
- look for postcss-loader
. Editing the configuration there can enable any postcss features.
PS: Look out for postcss-preset-env
in the default configuration while enabling nesting. Tailwind requires you to edit configuration if this is present.
QUESTION
Apollo Client "Named export 'remove' not found"
Asked 2022-Mar-12 at 09:45I'm attempting to create an apollo client
plugin for a Nuxt 3
application. It's currently throwing an error regarding a package called ts-invariant
:
1file:///Users/[my name]/Repositories/[project]/node_modules/@apollo/client/utilities/globals/fix-graphql.js:1
2import { remove } from "ts-invariant/process/index.js";
3 ^^^^^^
4SyntaxError: Named export 'remove' not found. The requested module 'ts-invariant/process/index.js' is a CommonJS module, which may not support all module.exports as named exports.
5CommonJS modules can always be imported via the default export, for example using:
6
7import pkg from 'ts-invariant/process/index.js';
8const { remove } = pkg;
9
10 at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
11 at async ModuleJob.run (node:internal/modules/esm/module_job:181:5)
12 at async Promise.all (index 0)
13 at async ESMLoader.import (node:internal/modules/esm/loader:281:24)
14 at async __instantiateModule__ (file:///Users/[my name]/Repositories/[project]/.nuxt/dist/server/server.mjs:4550:3)
15[vite dev] Error loading external "/Users/[my name]/Repositories/[project]/node_modules/@apollo/client/core/index.js".
16 at file://./.nuxt/dist/server/server.mjs:3170:289
17 at async __instantiateModule__ (file://./.nuxt/dist/server/server.mjs:4550:3)
18
I feel like I know enough about this error to know it has something to do with how Nuxt 3 deals with ESM, but I can't be for certain.
Here's the nuxt plugin:
plugins/apollo-client.js
1file:///Users/[my name]/Repositories/[project]/node_modules/@apollo/client/utilities/globals/fix-graphql.js:1
2import { remove } from "ts-invariant/process/index.js";
3 ^^^^^^
4SyntaxError: Named export 'remove' not found. The requested module 'ts-invariant/process/index.js' is a CommonJS module, which may not support all module.exports as named exports.
5CommonJS modules can always be imported via the default export, for example using:
6
7import pkg from 'ts-invariant/process/index.js';
8const { remove } = pkg;
9
10 at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
11 at async ModuleJob.run (node:internal/modules/esm/module_job:181:5)
12 at async Promise.all (index 0)
13 at async ESMLoader.import (node:internal/modules/esm/loader:281:24)
14 at async __instantiateModule__ (file:///Users/[my name]/Repositories/[project]/.nuxt/dist/server/server.mjs:4550:3)
15[vite dev] Error loading external "/Users/[my name]/Repositories/[project]/node_modules/@apollo/client/core/index.js".
16 at file://./.nuxt/dist/server/server.mjs:3170:289
17 at async __instantiateModule__ (file://./.nuxt/dist/server/server.mjs:4550:3)
18import { defineNuxtPlugin } from "#app"
19import { ApolloClient, InMemoryCache } from "@apollo/client/core"
20import { DefaultApolloClient } from "@vue/apollo-composable"
21
22export default defineNuxtPlugin((nuxtApp) => {
23 const config = useRuntimeConfig()
24 const apolloClient = new ApolloClient({
25 uri: config.PUBLIC_API_ENDPOINT,
26 cache: new InMemoryCache(),
27 })
28 nuxtApp.vueApp.provide(DefaultApolloClient, apolloClient)
29})
30
In a normal scenario, I might use the nuxt-apollo community module, but it is currently afk regarding a nuxt 3
port, so a plugin it is.
Here's some documentation I relied on for my plugin:
https://v4.apollo.vuejs.org/guide-composable/setup.html#vue-3
https://v3.nuxtjs.org/docs/directory-structure/plugins
ANSWER
Answered 2022-Jan-07 at 01:52Solved by including @apollo/client
and ts-invariant/process
into the nuxt build transpile like so:
1file:///Users/[my name]/Repositories/[project]/node_modules/@apollo/client/utilities/globals/fix-graphql.js:1
2import { remove } from "ts-invariant/process/index.js";
3 ^^^^^^
4SyntaxError: Named export 'remove' not found. The requested module 'ts-invariant/process/index.js' is a CommonJS module, which may not support all module.exports as named exports.
5CommonJS modules can always be imported via the default export, for example using:
6
7import pkg from 'ts-invariant/process/index.js';
8const { remove } = pkg;
9
10 at ModuleJob._instantiate (node:internal/modules/esm/module_job:124:21)
11 at async ModuleJob.run (node:internal/modules/esm/module_job:181:5)
12 at async Promise.all (index 0)
13 at async ESMLoader.import (node:internal/modules/esm/loader:281:24)
14 at async __instantiateModule__ (file:///Users/[my name]/Repositories/[project]/.nuxt/dist/server/server.mjs:4550:3)
15[vite dev] Error loading external "/Users/[my name]/Repositories/[project]/node_modules/@apollo/client/core/index.js".
16 at file://./.nuxt/dist/server/server.mjs:3170:289
17 at async __instantiateModule__ (file://./.nuxt/dist/server/server.mjs:4550:3)
18import { defineNuxtPlugin } from "#app"
19import { ApolloClient, InMemoryCache } from "@apollo/client/core"
20import { DefaultApolloClient } from "@vue/apollo-composable"
21
22export default defineNuxtPlugin((nuxtApp) => {
23 const config = useRuntimeConfig()
24 const apolloClient = new ApolloClient({
25 uri: config.PUBLIC_API_ENDPOINT,
26 cache: new InMemoryCache(),
27 })
28 nuxtApp.vueApp.provide(DefaultApolloClient, apolloClient)
29})
30 // nuxt.config.js
31 // ...
32 build: {
33 postcss: {
34 postcssOptions: require('./postcss.config.js')
35 },
36 transpile: [
37 '@apollo/client',
38 'ts-invariant/process',
39 ],
40 },
41 // ...
42
QUESTION
Nuxt3: how to use tailwindcss
Asked 2022-Mar-02 at 14:50Very first try on Nuxt3 via Nuxt3 Starter
I wonder how can I use tailwindcss in Nuxt3 Starter manually.
(Not via @nuxtjs/tailwindcss , because it's for Nuxt2, and not work with Nuxt3.)
I created a blank Nuxt3 project by
1npx degit "nuxt/starter#v3" my-nuxt3-project
2
then, I installed the tailwindcss manually
1npx degit "nuxt/starter#v3" my-nuxt3-project
2npm install -D tailwindcss@latest postcss@latest autoprefixer@latest
3
nuxt.config.ts
1npx degit "nuxt/starter#v3" my-nuxt3-project
2npm install -D tailwindcss@latest postcss@latest autoprefixer@latest
3export default {
4 css: [
5 '~/assets/tailwind.css',
6 ]
7}
8
assets/tailwind.css
1npx degit "nuxt/starter#v3" my-nuxt3-project
2npm install -D tailwindcss@latest postcss@latest autoprefixer@latest
3export default {
4 css: [
5 '~/assets/tailwind.css',
6 ]
7}
8@tailwind base;
9@tailwind components;
10@tailwind utilities;
11
but I can only get the raw code but not the compiled css:
How can I use tailwindcss in Nuxt3?
Any help is greatly appreciated!
ANSWER
Answered 2021-Oct-04 at 04:17Maybe your problem is because you need a tailwindcss.config.js
.
For this, simply type in the console:
1npx degit "nuxt/starter#v3" my-nuxt3-project
2npm install -D tailwindcss@latest postcss@latest autoprefixer@latest
3export default {
4 css: [
5 '~/assets/tailwind.css',
6 ]
7}
8@tailwind base;
9@tailwind components;
10@tailwind utilities;
11yarn run tailwindcss init
12
QUESTION
Laravel Mix URL Processing error with css-loader
Asked 2022-Feb-22 at 10:55In a fresh Laravel 9 installation, the URL processing from Laravel Mix does not work anymore.
npm outputs the following:
1✖ Mix
2 Compiled with some errors in 2.62s
3
4ERROR in ./resources/css/app.css
5Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
6ModuleBuildError: Module build failed (from ./node_modules/css-loader/dist/cjs.js):
7Error: Can't resolve './fonts/Inter-Regular.woff' in '/mnt/c/projects/test-project/resources/css'
8 at finishWithoutResolve (/mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:304:18)
9 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:381:15
10 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
11 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:16:1)
12 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
13 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:27:1)
14 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:87:43
15 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
16 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
17 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
18 at processResult (/mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:753:19)
19 at /mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:855:5
20 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:399:11
21 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:251:18
22 at context.callback (/mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:124:13)
23 at Object.loader (/mnt/c/projects/test-project/node_modules/css-loader/dist/index.js:155:5)
24 at runMicrotasks (<anonymous>)
25 at processTicksAndRejections (node:internal/process/task_queues:96:5)
26
271 ERROR in child compilations (Use 'stats.children: true' resp. '--stats-children' for more details)
28webpack compiled with 2 errors
29
The font file is just one of many. My app.css looks like this:
1✖ Mix
2 Compiled with some errors in 2.62s
3
4ERROR in ./resources/css/app.css
5Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
6ModuleBuildError: Module build failed (from ./node_modules/css-loader/dist/cjs.js):
7Error: Can't resolve './fonts/Inter-Regular.woff' in '/mnt/c/projects/test-project/resources/css'
8 at finishWithoutResolve (/mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:304:18)
9 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:381:15
10 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
11 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:16:1)
12 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
13 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:27:1)
14 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:87:43
15 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
16 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
17 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
18 at processResult (/mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:753:19)
19 at /mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:855:5
20 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:399:11
21 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:251:18
22 at context.callback (/mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:124:13)
23 at Object.loader (/mnt/c/projects/test-project/node_modules/css-loader/dist/index.js:155:5)
24 at runMicrotasks (<anonymous>)
25 at processTicksAndRejections (node:internal/process/task_queues:96:5)
26
271 ERROR in child compilations (Use 'stats.children: true' resp. '--stats-children' for more details)
28webpack compiled with 2 errors
29@import 'tailwindcss/base';
30@import 'tailwindcss/components';
31@import 'tailwindcss/utilities';
32
33@import 'primevue/resources/primevue.css';
34@import 'primevue/resources/themes/lara-light-indigo/theme.css';
35@import 'primeflex/primeflex.css';
36@import 'primeicons/primeicons.css';
37
The package.json contains the following dependencies/versions:
1✖ Mix
2 Compiled with some errors in 2.62s
3
4ERROR in ./resources/css/app.css
5Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
6ModuleBuildError: Module build failed (from ./node_modules/css-loader/dist/cjs.js):
7Error: Can't resolve './fonts/Inter-Regular.woff' in '/mnt/c/projects/test-project/resources/css'
8 at finishWithoutResolve (/mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:304:18)
9 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:381:15
10 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
11 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:16:1)
12 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
13 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:27:1)
14 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:87:43
15 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
16 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
17 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
18 at processResult (/mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:753:19)
19 at /mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:855:5
20 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:399:11
21 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:251:18
22 at context.callback (/mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:124:13)
23 at Object.loader (/mnt/c/projects/test-project/node_modules/css-loader/dist/index.js:155:5)
24 at runMicrotasks (<anonymous>)
25 at processTicksAndRejections (node:internal/process/task_queues:96:5)
26
271 ERROR in child compilations (Use 'stats.children: true' resp. '--stats-children' for more details)
28webpack compiled with 2 errors
29@import 'tailwindcss/base';
30@import 'tailwindcss/components';
31@import 'tailwindcss/utilities';
32
33@import 'primevue/resources/primevue.css';
34@import 'primevue/resources/themes/lara-light-indigo/theme.css';
35@import 'primeflex/primeflex.css';
36@import 'primeicons/primeicons.css';
37 "devDependencies": {
38 "@inertiajs/inertia": "^0.10.0",
39 "@inertiajs/inertia-vue3": "^0.5.1",
40 "@inertiajs/progress": "^0.2.6",
41 "@tailwindcss/forms": "^0.4.0",
42 "@vue/compiler-sfc": "^3.0.5",
43 "autoprefixer": "^10.2.4",
44 "axios": "^0.25",
45 "laravel-mix": "^6.0.6",
46 "lodash": "^4.17.19",
47 "postcss": "^8.2.13",
48 "postcss-import": "^14.0.1",
49 "tailwindcss": "^3.0.0",
50 "vue": "^3.0.5",
51 "vue-loader": "^16.1.2"
52 },
53 "dependencies": {
54 "primeflex": "^3.1.2",
55 "primeicons": "^5.0.0",
56 "primevue": "^3.11.1",
57 "vue-i18n": "^9.1.9"
58 }
59
The webpack.mix.js is default:
1✖ Mix
2 Compiled with some errors in 2.62s
3
4ERROR in ./resources/css/app.css
5Module build failed (from ./node_modules/mini-css-extract-plugin/dist/loader.js):
6ModuleBuildError: Module build failed (from ./node_modules/css-loader/dist/cjs.js):
7Error: Can't resolve './fonts/Inter-Regular.woff' in '/mnt/c/projects/test-project/resources/css'
8 at finishWithoutResolve (/mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:304:18)
9 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:381:15
10 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
11 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:16:1)
12 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
13 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:27:1)
14 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/DescriptionFilePlugin.js:87:43
15 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
16 at eval (eval at create (/mnt/c/projects/test-project/node_modules/tapable/lib/HookCodeFactory.js:33:10), <anonymous>:15:1)
17 at /mnt/c/projects/test-project/node_modules/enhanced-resolve/lib/Resolver.js:430:5
18 at processResult (/mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:753:19)
19 at /mnt/c/projects/test-project/node_modules/webpack/lib/NormalModule.js:855:5
20 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:399:11
21 at /mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:251:18
22 at context.callback (/mnt/c/projects/test-project/node_modules/loader-runner/lib/LoaderRunner.js:124:13)
23 at Object.loader (/mnt/c/projects/test-project/node_modules/css-loader/dist/index.js:155:5)
24 at runMicrotasks (<anonymous>)
25 at processTicksAndRejections (node:internal/process/task_queues:96:5)
26
271 ERROR in child compilations (Use 'stats.children: true' resp. '--stats-children' for more details)
28webpack compiled with 2 errors
29@import 'tailwindcss/base';
30@import 'tailwindcss/components';
31@import 'tailwindcss/utilities';
32
33@import 'primevue/resources/primevue.css';
34@import 'primevue/resources/themes/lara-light-indigo/theme.css';
35@import 'primeflex/primeflex.css';
36@import 'primeicons/primeicons.css';
37 "devDependencies": {
38 "@inertiajs/inertia": "^0.10.0",
39 "@inertiajs/inertia-vue3": "^0.5.1",
40 "@inertiajs/progress": "^0.2.6",
41 "@tailwindcss/forms": "^0.4.0",
42 "@vue/compiler-sfc": "^3.0.5",
43 "autoprefixer": "^10.2.4",
44 "axios": "^0.25",
45 "laravel-mix": "^6.0.6",
46 "lodash": "^4.17.19",
47 "postcss": "^8.2.13",
48 "postcss-import": "^14.0.1",
49 "tailwindcss": "^3.0.0",
50 "vue": "^3.0.5",
51 "vue-loader": "^16.1.2"
52 },
53 "dependencies": {
54 "primeflex": "^3.1.2",
55 "primeicons": "^5.0.0",
56 "primevue": "^3.11.1",
57 "vue-i18n": "^9.1.9"
58 }
59mix.js('resources/js/app.js', 'public/js')
60 .vue()
61 .postCss('resources/css/app.css', 'public/css', [
62 require('postcss-import'),
63 require('tailwindcss'),
64 require('autoprefixer'),
65 ])
66 .webpackConfig(require('./webpack.config'));
67
Is there something I haven't seen?
ANSWER
Answered 2022-Feb-22 at 10:55Actually moving the css imports into resources/js/app.js
solves this problem. However, this results in the imported css to be included in the public/js/app.js
, not the public/css/app.css
.
QUESTION
How to get 2D scene coordinates of a 3D object in JavaFX
Asked 2022-Feb-02 at 12:28I'm trying the create a 3D subscene with objects being labelled using Label objects in a 2D overlay. I've seen similar questions to mine on this subject, and they all point to using the Node.localToScene method on the node to be labelled in the 3D space. But this doesn't seem to work for my case. I've taken example code from the FXyz FloatingLabels example here:
The Label objects need to have their positions updated as the 3D scene in modified, which I've done but when I print out the coordinates returned by the Node.localToScene method, they're much too large to be within the application scene, and so the labels are never visible in the scene. I've written an example program that illustrates the issue, set up very similarly to the FXyz sample code but I've created an extra SubScene object to hold the 2D and 3D SubScene objects in order to plant them into a larger application window with slider controls. The 3D scene uses a perspective camera and shows a large sphere with coloured spheres along the x/y/z axes, and some extra little nubs on the surface for reference:
1import javafx.application.Application;
2import javafx.application.Platform;
3import javafx.scene.Group;
4import javafx.scene.Node;
5import javafx.scene.PerspectiveCamera;
6import javafx.scene.SubScene;
7import javafx.scene.Scene;
8import javafx.scene.SceneAntialiasing;
9import javafx.scene.AmbientLight;
10import javafx.scene.PointLight;
11import javafx.scene.control.Label;
12import javafx.scene.control.Slider;
13import javafx.scene.control.ToolBar;
14import javafx.scene.layout.GridPane;
15import javafx.scene.layout.StackPane;
16import javafx.scene.layout.Priority;
17import javafx.scene.shape.Sphere;
18import javafx.scene.paint.Color;
19import javafx.scene.paint.PhongMaterial;
20import javafx.scene.transform.Rotate;
21import javafx.scene.transform.Translate;
22import javafx.stage.Stage;
23import javafx.geometry.Point3D;
24
25import java.util.Map;
26import java.util.HashMap;
27
28public class LabelTest extends Application {
29
30 private Map<Node, Label> nodeToLabelMap;
31
32 @Override
33 public void start (Stage stage) {
34
35 // Create main scene graph
36
37 var objects3d = new Group();
38
39 Rotate xRotate = new Rotate (0, 0, 0, 0, Rotate.X_AXIS);
40 Rotate yRotate = new Rotate (0, 0, 0, 0, Rotate.Y_AXIS);
41 objects3d.getTransforms().addAll (
42 xRotate,
43 yRotate
44 );
45
46 var root3d = new Group();
47 root3d.getChildren().add (objects3d);
48
49 var camera = new PerspectiveCamera (true);
50 camera.setTranslateZ (-25);
51
52 var scene3d = new SubScene (root3d, 500, 500, true, SceneAntialiasing.BALANCED);
53 scene3d.setFill (Color.rgb (20, 20, 80));
54 scene3d.setCamera (camera);
55
56 var sceneRoot = new Group (scene3d);
57 var objects2d = new Group();
58 sceneRoot.getChildren().add (objects2d);
59 var viewScene = new SubScene (sceneRoot, 500, 500);
60
61 scene3d.widthProperty().bind (viewScene.widthProperty());
62 scene3d.heightProperty().bind (viewScene.heightProperty());
63
64 // Add lights and objects
65
66 var ambient = new AmbientLight (Color.color (0.7, 0.7, 0.7));
67 var point = new PointLight (Color.color (0.3, 0.3, 0.3));
68 point.setTranslateX (-25);
69 point.setTranslateY (-25);
70 point.setTranslateZ (-50);
71
72 root3d.getChildren().addAll (ambient, point);
73
74 var globe = new Sphere (5);
75 globe.setMaterial (new PhongMaterial (Color.color (0.3, 0.3, 0.3)));
76
77 var xSphere = new Sphere (0.5);
78 xSphere.setMaterial (new PhongMaterial (Color.RED));
79 xSphere.setTranslateX (5);
80
81 var ySphere = new Sphere (0.5);
82 ySphere.setMaterial (new PhongMaterial (Color.GREEN));
83 ySphere.setTranslateY (5);
84
85 var zSphere = new Sphere (0.5);
86 zSphere.setMaterial (new PhongMaterial (Color.BLUE));
87 zSphere.setTranslateZ (5);
88
89 objects3d.getChildren().addAll (globe, xSphere, ySphere, zSphere);
90
91 var nubMaterial = new PhongMaterial (Color.color (0.2, 0.2, 0.2));
92 for (int i = 0; i < 200; i++) {
93 var nub = new Sphere (0.125);
94 nub.setMaterial (nubMaterial);
95 var phi = 2*Math.PI*Math.random();
96 var theta = Math.acos (2*Math.random() - 1);
97 var z = -5 * Math.sin (theta) * Math.cos (phi);
98 var x = 5 * Math.sin (theta) * Math.sin (phi);
99 var y = -5 * Math.cos (theta);
100 nub.setTranslateX (x);
101 nub.setTranslateY (y);
102 nub.setTranslateZ (z);
103 objects3d.getChildren().add (nub);
104 } // for
105
106 // Add labels
107
108 var xLabel = new Label ("X axis");
109 xLabel.setTextFill (Color.RED);
110
111 var yLabel = new Label ("Y axis");
112 yLabel.setTextFill (Color.GREEN);
113
114 var zLabel = new Label ("Z axis");
115 zLabel.setTextFill (Color.BLUE);
116
117 objects2d.getChildren().addAll (xLabel, yLabel, zLabel);
118
119 nodeToLabelMap = new HashMap<>();
120 nodeToLabelMap.put (xSphere, xLabel);
121 nodeToLabelMap.put (ySphere, yLabel);
122 nodeToLabelMap.put (zSphere, zLabel);
123
124 xRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
125 yRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
126 camera.translateZProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
127 Platform.runLater (() -> updateLabels());
128
129 // Create main pane
130
131 var gridPane = new GridPane();
132
133 var stackPane = new StackPane (viewScene);
134 viewScene.heightProperty().bind (stackPane.heightProperty());
135 viewScene.widthProperty().bind (stackPane.widthProperty());
136 viewScene.setManaged (false);
137
138 gridPane.add (stackPane, 0, 0);
139 gridPane.setVgrow (stackPane, Priority.ALWAYS);
140 gridPane.setHgrow (stackPane, Priority.ALWAYS);
141
142 // Add controls
143
144 var xSlider = new Slider (-90, 90, 0);
145 xRotate.angleProperty().bind (xSlider.valueProperty());
146 var ySlider = new Slider (-180, 180, 0);
147 yRotate.angleProperty().bind (ySlider.valueProperty());
148 var zSlider = new Slider (-60, -25, -25);
149 camera.translateZProperty().bind (zSlider.valueProperty());
150
151 ToolBar toolbar = new ToolBar (
152 new Label ("X rotation:"),
153 xSlider,
154 new Label ("Y rotation:"),
155 ySlider,
156 new Label ("Z position:"),
157 zSlider
158 );
159 gridPane.add (toolbar, 0, 1);
160
161 // Start the show
162
163 stage.setTitle ("Label Test");
164 stage.setScene (new Scene (gridPane, 800, 600));
165 stage.show();
166
167 } // start
168
169 private void updateLabels () {
170
171 nodeToLabelMap.forEach ((node, label) -> {
172 var coord = node.localToScene (Point3D.ZERO, true);
173 System.out.println ("label = " + label.getText() + ", coord = " + coord);
174 label.getTransforms().setAll (new Translate(coord.getX(), coord.getY()));
175 });
176
177 } // updateLabels
178
179 public static void main (String[] args) {
180
181 launch (args);
182
183 } // main
184
185} // LabelTest class
186
You can compile and run the LabelTest.java program using this script (I'm using JavaFX 14 and JDK 14.0.2 on a Mac):
1import javafx.application.Application;
2import javafx.application.Platform;
3import javafx.scene.Group;
4import javafx.scene.Node;
5import javafx.scene.PerspectiveCamera;
6import javafx.scene.SubScene;
7import javafx.scene.Scene;
8import javafx.scene.SceneAntialiasing;
9import javafx.scene.AmbientLight;
10import javafx.scene.PointLight;
11import javafx.scene.control.Label;
12import javafx.scene.control.Slider;
13import javafx.scene.control.ToolBar;
14import javafx.scene.layout.GridPane;
15import javafx.scene.layout.StackPane;
16import javafx.scene.layout.Priority;
17import javafx.scene.shape.Sphere;
18import javafx.scene.paint.Color;
19import javafx.scene.paint.PhongMaterial;
20import javafx.scene.transform.Rotate;
21import javafx.scene.transform.Translate;
22import javafx.stage.Stage;
23import javafx.geometry.Point3D;
24
25import java.util.Map;
26import java.util.HashMap;
27
28public class LabelTest extends Application {
29
30 private Map<Node, Label> nodeToLabelMap;
31
32 @Override
33 public void start (Stage stage) {
34
35 // Create main scene graph
36
37 var objects3d = new Group();
38
39 Rotate xRotate = new Rotate (0, 0, 0, 0, Rotate.X_AXIS);
40 Rotate yRotate = new Rotate (0, 0, 0, 0, Rotate.Y_AXIS);
41 objects3d.getTransforms().addAll (
42 xRotate,
43 yRotate
44 );
45
46 var root3d = new Group();
47 root3d.getChildren().add (objects3d);
48
49 var camera = new PerspectiveCamera (true);
50 camera.setTranslateZ (-25);
51
52 var scene3d = new SubScene (root3d, 500, 500, true, SceneAntialiasing.BALANCED);
53 scene3d.setFill (Color.rgb (20, 20, 80));
54 scene3d.setCamera (camera);
55
56 var sceneRoot = new Group (scene3d);
57 var objects2d = new Group();
58 sceneRoot.getChildren().add (objects2d);
59 var viewScene = new SubScene (sceneRoot, 500, 500);
60
61 scene3d.widthProperty().bind (viewScene.widthProperty());
62 scene3d.heightProperty().bind (viewScene.heightProperty());
63
64 // Add lights and objects
65
66 var ambient = new AmbientLight (Color.color (0.7, 0.7, 0.7));
67 var point = new PointLight (Color.color (0.3, 0.3, 0.3));
68 point.setTranslateX (-25);
69 point.setTranslateY (-25);
70 point.setTranslateZ (-50);
71
72 root3d.getChildren().addAll (ambient, point);
73
74 var globe = new Sphere (5);
75 globe.setMaterial (new PhongMaterial (Color.color (0.3, 0.3, 0.3)));
76
77 var xSphere = new Sphere (0.5);
78 xSphere.setMaterial (new PhongMaterial (Color.RED));
79 xSphere.setTranslateX (5);
80
81 var ySphere = new Sphere (0.5);
82 ySphere.setMaterial (new PhongMaterial (Color.GREEN));
83 ySphere.setTranslateY (5);
84
85 var zSphere = new Sphere (0.5);
86 zSphere.setMaterial (new PhongMaterial (Color.BLUE));
87 zSphere.setTranslateZ (5);
88
89 objects3d.getChildren().addAll (globe, xSphere, ySphere, zSphere);
90
91 var nubMaterial = new PhongMaterial (Color.color (0.2, 0.2, 0.2));
92 for (int i = 0; i < 200; i++) {
93 var nub = new Sphere (0.125);
94 nub.setMaterial (nubMaterial);
95 var phi = 2*Math.PI*Math.random();
96 var theta = Math.acos (2*Math.random() - 1);
97 var z = -5 * Math.sin (theta) * Math.cos (phi);
98 var x = 5 * Math.sin (theta) * Math.sin (phi);
99 var y = -5 * Math.cos (theta);
100 nub.setTranslateX (x);
101 nub.setTranslateY (y);
102 nub.setTranslateZ (z);
103 objects3d.getChildren().add (nub);
104 } // for
105
106 // Add labels
107
108 var xLabel = new Label ("X axis");
109 xLabel.setTextFill (Color.RED);
110
111 var yLabel = new Label ("Y axis");
112 yLabel.setTextFill (Color.GREEN);
113
114 var zLabel = new Label ("Z axis");
115 zLabel.setTextFill (Color.BLUE);
116
117 objects2d.getChildren().addAll (xLabel, yLabel, zLabel);
118
119 nodeToLabelMap = new HashMap<>();
120 nodeToLabelMap.put (xSphere, xLabel);
121 nodeToLabelMap.put (ySphere, yLabel);
122 nodeToLabelMap.put (zSphere, zLabel);
123
124 xRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
125 yRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
126 camera.translateZProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
127 Platform.runLater (() -> updateLabels());
128
129 // Create main pane
130
131 var gridPane = new GridPane();
132
133 var stackPane = new StackPane (viewScene);
134 viewScene.heightProperty().bind (stackPane.heightProperty());
135 viewScene.widthProperty().bind (stackPane.widthProperty());
136 viewScene.setManaged (false);
137
138 gridPane.add (stackPane, 0, 0);
139 gridPane.setVgrow (stackPane, Priority.ALWAYS);
140 gridPane.setHgrow (stackPane, Priority.ALWAYS);
141
142 // Add controls
143
144 var xSlider = new Slider (-90, 90, 0);
145 xRotate.angleProperty().bind (xSlider.valueProperty());
146 var ySlider = new Slider (-180, 180, 0);
147 yRotate.angleProperty().bind (ySlider.valueProperty());
148 var zSlider = new Slider (-60, -25, -25);
149 camera.translateZProperty().bind (zSlider.valueProperty());
150
151 ToolBar toolbar = new ToolBar (
152 new Label ("X rotation:"),
153 xSlider,
154 new Label ("Y rotation:"),
155 ySlider,
156 new Label ("Z position:"),
157 zSlider
158 );
159 gridPane.add (toolbar, 0, 1);
160
161 // Start the show
162
163 stage.setTitle ("Label Test");
164 stage.setScene (new Scene (gridPane, 800, 600));
165 stage.show();
166
167 } // start
168
169 private void updateLabels () {
170
171 nodeToLabelMap.forEach ((node, label) -> {
172 var coord = node.localToScene (Point3D.ZERO, true);
173 System.out.println ("label = " + label.getText() + ", coord = " + coord);
174 label.getTransforms().setAll (new Translate(coord.getX(), coord.getY()));
175 });
176
177 } // updateLabels
178
179 public static void main (String[] args) {
180
181 launch (args);
182
183 } // main
184
185} // LabelTest class
186#!/bin/sh
187
188set -x
189
190export PATH_TO_FX=javafx-sdk-14/lib
191
192javac --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest.java
193if [ $? -ne 0 ] ; then
194 exit 1
195fi
196
197java -cp . --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest
198
My test program output contains very large label coordinates that don't represent the position of the coloured axis spheres, for example:
1import javafx.application.Application;
2import javafx.application.Platform;
3import javafx.scene.Group;
4import javafx.scene.Node;
5import javafx.scene.PerspectiveCamera;
6import javafx.scene.SubScene;
7import javafx.scene.Scene;
8import javafx.scene.SceneAntialiasing;
9import javafx.scene.AmbientLight;
10import javafx.scene.PointLight;
11import javafx.scene.control.Label;
12import javafx.scene.control.Slider;
13import javafx.scene.control.ToolBar;
14import javafx.scene.layout.GridPane;
15import javafx.scene.layout.StackPane;
16import javafx.scene.layout.Priority;
17import javafx.scene.shape.Sphere;
18import javafx.scene.paint.Color;
19import javafx.scene.paint.PhongMaterial;
20import javafx.scene.transform.Rotate;
21import javafx.scene.transform.Translate;
22import javafx.stage.Stage;
23import javafx.geometry.Point3D;
24
25import java.util.Map;
26import java.util.HashMap;
27
28public class LabelTest extends Application {
29
30 private Map<Node, Label> nodeToLabelMap;
31
32 @Override
33 public void start (Stage stage) {
34
35 // Create main scene graph
36
37 var objects3d = new Group();
38
39 Rotate xRotate = new Rotate (0, 0, 0, 0, Rotate.X_AXIS);
40 Rotate yRotate = new Rotate (0, 0, 0, 0, Rotate.Y_AXIS);
41 objects3d.getTransforms().addAll (
42 xRotate,
43 yRotate
44 );
45
46 var root3d = new Group();
47 root3d.getChildren().add (objects3d);
48
49 var camera = new PerspectiveCamera (true);
50 camera.setTranslateZ (-25);
51
52 var scene3d = new SubScene (root3d, 500, 500, true, SceneAntialiasing.BALANCED);
53 scene3d.setFill (Color.rgb (20, 20, 80));
54 scene3d.setCamera (camera);
55
56 var sceneRoot = new Group (scene3d);
57 var objects2d = new Group();
58 sceneRoot.getChildren().add (objects2d);
59 var viewScene = new SubScene (sceneRoot, 500, 500);
60
61 scene3d.widthProperty().bind (viewScene.widthProperty());
62 scene3d.heightProperty().bind (viewScene.heightProperty());
63
64 // Add lights and objects
65
66 var ambient = new AmbientLight (Color.color (0.7, 0.7, 0.7));
67 var point = new PointLight (Color.color (0.3, 0.3, 0.3));
68 point.setTranslateX (-25);
69 point.setTranslateY (-25);
70 point.setTranslateZ (-50);
71
72 root3d.getChildren().addAll (ambient, point);
73
74 var globe = new Sphere (5);
75 globe.setMaterial (new PhongMaterial (Color.color (0.3, 0.3, 0.3)));
76
77 var xSphere = new Sphere (0.5);
78 xSphere.setMaterial (new PhongMaterial (Color.RED));
79 xSphere.setTranslateX (5);
80
81 var ySphere = new Sphere (0.5);
82 ySphere.setMaterial (new PhongMaterial (Color.GREEN));
83 ySphere.setTranslateY (5);
84
85 var zSphere = new Sphere (0.5);
86 zSphere.setMaterial (new PhongMaterial (Color.BLUE));
87 zSphere.setTranslateZ (5);
88
89 objects3d.getChildren().addAll (globe, xSphere, ySphere, zSphere);
90
91 var nubMaterial = new PhongMaterial (Color.color (0.2, 0.2, 0.2));
92 for (int i = 0; i < 200; i++) {
93 var nub = new Sphere (0.125);
94 nub.setMaterial (nubMaterial);
95 var phi = 2*Math.PI*Math.random();
96 var theta = Math.acos (2*Math.random() - 1);
97 var z = -5 * Math.sin (theta) * Math.cos (phi);
98 var x = 5 * Math.sin (theta) * Math.sin (phi);
99 var y = -5 * Math.cos (theta);
100 nub.setTranslateX (x);
101 nub.setTranslateY (y);
102 nub.setTranslateZ (z);
103 objects3d.getChildren().add (nub);
104 } // for
105
106 // Add labels
107
108 var xLabel = new Label ("X axis");
109 xLabel.setTextFill (Color.RED);
110
111 var yLabel = new Label ("Y axis");
112 yLabel.setTextFill (Color.GREEN);
113
114 var zLabel = new Label ("Z axis");
115 zLabel.setTextFill (Color.BLUE);
116
117 objects2d.getChildren().addAll (xLabel, yLabel, zLabel);
118
119 nodeToLabelMap = new HashMap<>();
120 nodeToLabelMap.put (xSphere, xLabel);
121 nodeToLabelMap.put (ySphere, yLabel);
122 nodeToLabelMap.put (zSphere, zLabel);
123
124 xRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
125 yRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
126 camera.translateZProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
127 Platform.runLater (() -> updateLabels());
128
129 // Create main pane
130
131 var gridPane = new GridPane();
132
133 var stackPane = new StackPane (viewScene);
134 viewScene.heightProperty().bind (stackPane.heightProperty());
135 viewScene.widthProperty().bind (stackPane.widthProperty());
136 viewScene.setManaged (false);
137
138 gridPane.add (stackPane, 0, 0);
139 gridPane.setVgrow (stackPane, Priority.ALWAYS);
140 gridPane.setHgrow (stackPane, Priority.ALWAYS);
141
142 // Add controls
143
144 var xSlider = new Slider (-90, 90, 0);
145 xRotate.angleProperty().bind (xSlider.valueProperty());
146 var ySlider = new Slider (-180, 180, 0);
147 yRotate.angleProperty().bind (ySlider.valueProperty());
148 var zSlider = new Slider (-60, -25, -25);
149 camera.translateZProperty().bind (zSlider.valueProperty());
150
151 ToolBar toolbar = new ToolBar (
152 new Label ("X rotation:"),
153 xSlider,
154 new Label ("Y rotation:"),
155 ySlider,
156 new Label ("Z position:"),
157 zSlider
158 );
159 gridPane.add (toolbar, 0, 1);
160
161 // Start the show
162
163 stage.setTitle ("Label Test");
164 stage.setScene (new Scene (gridPane, 800, 600));
165 stage.show();
166
167 } // start
168
169 private void updateLabels () {
170
171 nodeToLabelMap.forEach ((node, label) -> {
172 var coord = node.localToScene (Point3D.ZERO, true);
173 System.out.println ("label = " + label.getText() + ", coord = " + coord);
174 label.getTransforms().setAll (new Translate(coord.getX(), coord.getY()));
175 });
176
177 } // updateLabels
178
179 public static void main (String[] args) {
180
181 launch (args);
182
183 } // main
184
185} // LabelTest class
186#!/bin/sh
187
188set -x
189
190export PATH_TO_FX=javafx-sdk-14/lib
191
192javac --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest.java
193if [ $? -ne 0 ] ; then
194 exit 1
195fi
196
197java -cp . --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest
198label = Y axis, coord = Point3D [x = 17448.00808897467, y = 21535.846392310217, z = 0.0]
199label = X axis, coord = Point3D [x = 26530.33870777918, y = 12453.515773505665, z = 0.0]
200label = Z axis, coord = Point3D [x = 17448.008088974653, y = 12453.515773505665, z = 0.0]
201
My display looks like this:
where as it should look more like the example from FXyz with labels next to the axis spheres:
ANSWER
Answered 2022-Feb-02 at 12:28If you follow what has been done in the link you have posted you'll make it work.
For starters, there is one subScene, not two.
So I've removed these lines:
1import javafx.application.Application;
2import javafx.application.Platform;
3import javafx.scene.Group;
4import javafx.scene.Node;
5import javafx.scene.PerspectiveCamera;
6import javafx.scene.SubScene;
7import javafx.scene.Scene;
8import javafx.scene.SceneAntialiasing;
9import javafx.scene.AmbientLight;
10import javafx.scene.PointLight;
11import javafx.scene.control.Label;
12import javafx.scene.control.Slider;
13import javafx.scene.control.ToolBar;
14import javafx.scene.layout.GridPane;
15import javafx.scene.layout.StackPane;
16import javafx.scene.layout.Priority;
17import javafx.scene.shape.Sphere;
18import javafx.scene.paint.Color;
19import javafx.scene.paint.PhongMaterial;
20import javafx.scene.transform.Rotate;
21import javafx.scene.transform.Translate;
22import javafx.stage.Stage;
23import javafx.geometry.Point3D;
24
25import java.util.Map;
26import java.util.HashMap;
27
28public class LabelTest extends Application {
29
30 private Map<Node, Label> nodeToLabelMap;
31
32 @Override
33 public void start (Stage stage) {
34
35 // Create main scene graph
36
37 var objects3d = new Group();
38
39 Rotate xRotate = new Rotate (0, 0, 0, 0, Rotate.X_AXIS);
40 Rotate yRotate = new Rotate (0, 0, 0, 0, Rotate.Y_AXIS);
41 objects3d.getTransforms().addAll (
42 xRotate,
43 yRotate
44 );
45
46 var root3d = new Group();
47 root3d.getChildren().add (objects3d);
48
49 var camera = new PerspectiveCamera (true);
50 camera.setTranslateZ (-25);
51
52 var scene3d = new SubScene (root3d, 500, 500, true, SceneAntialiasing.BALANCED);
53 scene3d.setFill (Color.rgb (20, 20, 80));
54 scene3d.setCamera (camera);
55
56 var sceneRoot = new Group (scene3d);
57 var objects2d = new Group();
58 sceneRoot.getChildren().add (objects2d);
59 var viewScene = new SubScene (sceneRoot, 500, 500);
60
61 scene3d.widthProperty().bind (viewScene.widthProperty());
62 scene3d.heightProperty().bind (viewScene.heightProperty());
63
64 // Add lights and objects
65
66 var ambient = new AmbientLight (Color.color (0.7, 0.7, 0.7));
67 var point = new PointLight (Color.color (0.3, 0.3, 0.3));
68 point.setTranslateX (-25);
69 point.setTranslateY (-25);
70 point.setTranslateZ (-50);
71
72 root3d.getChildren().addAll (ambient, point);
73
74 var globe = new Sphere (5);
75 globe.setMaterial (new PhongMaterial (Color.color (0.3, 0.3, 0.3)));
76
77 var xSphere = new Sphere (0.5);
78 xSphere.setMaterial (new PhongMaterial (Color.RED));
79 xSphere.setTranslateX (5);
80
81 var ySphere = new Sphere (0.5);
82 ySphere.setMaterial (new PhongMaterial (Color.GREEN));
83 ySphere.setTranslateY (5);
84
85 var zSphere = new Sphere (0.5);
86 zSphere.setMaterial (new PhongMaterial (Color.BLUE));
87 zSphere.setTranslateZ (5);
88
89 objects3d.getChildren().addAll (globe, xSphere, ySphere, zSphere);
90
91 var nubMaterial = new PhongMaterial (Color.color (0.2, 0.2, 0.2));
92 for (int i = 0; i < 200; i++) {
93 var nub = new Sphere (0.125);
94 nub.setMaterial (nubMaterial);
95 var phi = 2*Math.PI*Math.random();
96 var theta = Math.acos (2*Math.random() - 1);
97 var z = -5 * Math.sin (theta) * Math.cos (phi);
98 var x = 5 * Math.sin (theta) * Math.sin (phi);
99 var y = -5 * Math.cos (theta);
100 nub.setTranslateX (x);
101 nub.setTranslateY (y);
102 nub.setTranslateZ (z);
103 objects3d.getChildren().add (nub);
104 } // for
105
106 // Add labels
107
108 var xLabel = new Label ("X axis");
109 xLabel.setTextFill (Color.RED);
110
111 var yLabel = new Label ("Y axis");
112 yLabel.setTextFill (Color.GREEN);
113
114 var zLabel = new Label ("Z axis");
115 zLabel.setTextFill (Color.BLUE);
116
117 objects2d.getChildren().addAll (xLabel, yLabel, zLabel);
118
119 nodeToLabelMap = new HashMap<>();
120 nodeToLabelMap.put (xSphere, xLabel);
121 nodeToLabelMap.put (ySphere, yLabel);
122 nodeToLabelMap.put (zSphere, zLabel);
123
124 xRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
125 yRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
126 camera.translateZProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
127 Platform.runLater (() -> updateLabels());
128
129 // Create main pane
130
131 var gridPane = new GridPane();
132
133 var stackPane = new StackPane (viewScene);
134 viewScene.heightProperty().bind (stackPane.heightProperty());
135 viewScene.widthProperty().bind (stackPane.widthProperty());
136 viewScene.setManaged (false);
137
138 gridPane.add (stackPane, 0, 0);
139 gridPane.setVgrow (stackPane, Priority.ALWAYS);
140 gridPane.setHgrow (stackPane, Priority.ALWAYS);
141
142 // Add controls
143
144 var xSlider = new Slider (-90, 90, 0);
145 xRotate.angleProperty().bind (xSlider.valueProperty());
146 var ySlider = new Slider (-180, 180, 0);
147 yRotate.angleProperty().bind (ySlider.valueProperty());
148 var zSlider = new Slider (-60, -25, -25);
149 camera.translateZProperty().bind (zSlider.valueProperty());
150
151 ToolBar toolbar = new ToolBar (
152 new Label ("X rotation:"),
153 xSlider,
154 new Label ("Y rotation:"),
155 ySlider,
156 new Label ("Z position:"),
157 zSlider
158 );
159 gridPane.add (toolbar, 0, 1);
160
161 // Start the show
162
163 stage.setTitle ("Label Test");
164 stage.setScene (new Scene (gridPane, 800, 600));
165 stage.show();
166
167 } // start
168
169 private void updateLabels () {
170
171 nodeToLabelMap.forEach ((node, label) -> {
172 var coord = node.localToScene (Point3D.ZERO, true);
173 System.out.println ("label = " + label.getText() + ", coord = " + coord);
174 label.getTransforms().setAll (new Translate(coord.getX(), coord.getY()));
175 });
176
177 } // updateLabels
178
179 public static void main (String[] args) {
180
181 launch (args);
182
183 } // main
184
185} // LabelTest class
186#!/bin/sh
187
188set -x
189
190export PATH_TO_FX=javafx-sdk-14/lib
191
192javac --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest.java
193if [ $? -ne 0 ] ; then
194 exit 1
195fi
196
197java -cp . --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest
198label = Y axis, coord = Point3D [x = 17448.00808897467, y = 21535.846392310217, z = 0.0]
199label = X axis, coord = Point3D [x = 26530.33870777918, y = 12453.515773505665, z = 0.0]
200label = Z axis, coord = Point3D [x = 17448.008088974653, y = 12453.515773505665, z = 0.0]
201- var viewScene = new SubScene (new Group (scene3d), 500, 500);
202
203- scene3d.widthProperty().bind (viewScene.widthProperty());
204- scene3d.heightProperty().bind (viewScene.heightProperty());
205
and replaced these:
1import javafx.application.Application;
2import javafx.application.Platform;
3import javafx.scene.Group;
4import javafx.scene.Node;
5import javafx.scene.PerspectiveCamera;
6import javafx.scene.SubScene;
7import javafx.scene.Scene;
8import javafx.scene.SceneAntialiasing;
9import javafx.scene.AmbientLight;
10import javafx.scene.PointLight;
11import javafx.scene.control.Label;
12import javafx.scene.control.Slider;
13import javafx.scene.control.ToolBar;
14import javafx.scene.layout.GridPane;
15import javafx.scene.layout.StackPane;
16import javafx.scene.layout.Priority;
17import javafx.scene.shape.Sphere;
18import javafx.scene.paint.Color;
19import javafx.scene.paint.PhongMaterial;
20import javafx.scene.transform.Rotate;
21import javafx.scene.transform.Translate;
22import javafx.stage.Stage;
23import javafx.geometry.Point3D;
24
25import java.util.Map;
26import java.util.HashMap;
27
28public class LabelTest extends Application {
29
30 private Map<Node, Label> nodeToLabelMap;
31
32 @Override
33 public void start (Stage stage) {
34
35 // Create main scene graph
36
37 var objects3d = new Group();
38
39 Rotate xRotate = new Rotate (0, 0, 0, 0, Rotate.X_AXIS);
40 Rotate yRotate = new Rotate (0, 0, 0, 0, Rotate.Y_AXIS);
41 objects3d.getTransforms().addAll (
42 xRotate,
43 yRotate
44 );
45
46 var root3d = new Group();
47 root3d.getChildren().add (objects3d);
48
49 var camera = new PerspectiveCamera (true);
50 camera.setTranslateZ (-25);
51
52 var scene3d = new SubScene (root3d, 500, 500, true, SceneAntialiasing.BALANCED);
53 scene3d.setFill (Color.rgb (20, 20, 80));
54 scene3d.setCamera (camera);
55
56 var sceneRoot = new Group (scene3d);
57 var objects2d = new Group();
58 sceneRoot.getChildren().add (objects2d);
59 var viewScene = new SubScene (sceneRoot, 500, 500);
60
61 scene3d.widthProperty().bind (viewScene.widthProperty());
62 scene3d.heightProperty().bind (viewScene.heightProperty());
63
64 // Add lights and objects
65
66 var ambient = new AmbientLight (Color.color (0.7, 0.7, 0.7));
67 var point = new PointLight (Color.color (0.3, 0.3, 0.3));
68 point.setTranslateX (-25);
69 point.setTranslateY (-25);
70 point.setTranslateZ (-50);
71
72 root3d.getChildren().addAll (ambient, point);
73
74 var globe = new Sphere (5);
75 globe.setMaterial (new PhongMaterial (Color.color (0.3, 0.3, 0.3)));
76
77 var xSphere = new Sphere (0.5);
78 xSphere.setMaterial (new PhongMaterial (Color.RED));
79 xSphere.setTranslateX (5);
80
81 var ySphere = new Sphere (0.5);
82 ySphere.setMaterial (new PhongMaterial (Color.GREEN));
83 ySphere.setTranslateY (5);
84
85 var zSphere = new Sphere (0.5);
86 zSphere.setMaterial (new PhongMaterial (Color.BLUE));
87 zSphere.setTranslateZ (5);
88
89 objects3d.getChildren().addAll (globe, xSphere, ySphere, zSphere);
90
91 var nubMaterial = new PhongMaterial (Color.color (0.2, 0.2, 0.2));
92 for (int i = 0; i < 200; i++) {
93 var nub = new Sphere (0.125);
94 nub.setMaterial (nubMaterial);
95 var phi = 2*Math.PI*Math.random();
96 var theta = Math.acos (2*Math.random() - 1);
97 var z = -5 * Math.sin (theta) * Math.cos (phi);
98 var x = 5 * Math.sin (theta) * Math.sin (phi);
99 var y = -5 * Math.cos (theta);
100 nub.setTranslateX (x);
101 nub.setTranslateY (y);
102 nub.setTranslateZ (z);
103 objects3d.getChildren().add (nub);
104 } // for
105
106 // Add labels
107
108 var xLabel = new Label ("X axis");
109 xLabel.setTextFill (Color.RED);
110
111 var yLabel = new Label ("Y axis");
112 yLabel.setTextFill (Color.GREEN);
113
114 var zLabel = new Label ("Z axis");
115 zLabel.setTextFill (Color.BLUE);
116
117 objects2d.getChildren().addAll (xLabel, yLabel, zLabel);
118
119 nodeToLabelMap = new HashMap<>();
120 nodeToLabelMap.put (xSphere, xLabel);
121 nodeToLabelMap.put (ySphere, yLabel);
122 nodeToLabelMap.put (zSphere, zLabel);
123
124 xRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
125 yRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
126 camera.translateZProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
127 Platform.runLater (() -> updateLabels());
128
129 // Create main pane
130
131 var gridPane = new GridPane();
132
133 var stackPane = new StackPane (viewScene);
134 viewScene.heightProperty().bind (stackPane.heightProperty());
135 viewScene.widthProperty().bind (stackPane.widthProperty());
136 viewScene.setManaged (false);
137
138 gridPane.add (stackPane, 0, 0);
139 gridPane.setVgrow (stackPane, Priority.ALWAYS);
140 gridPane.setHgrow (stackPane, Priority.ALWAYS);
141
142 // Add controls
143
144 var xSlider = new Slider (-90, 90, 0);
145 xRotate.angleProperty().bind (xSlider.valueProperty());
146 var ySlider = new Slider (-180, 180, 0);
147 yRotate.angleProperty().bind (ySlider.valueProperty());
148 var zSlider = new Slider (-60, -25, -25);
149 camera.translateZProperty().bind (zSlider.valueProperty());
150
151 ToolBar toolbar = new ToolBar (
152 new Label ("X rotation:"),
153 xSlider,
154 new Label ("Y rotation:"),
155 ySlider,
156 new Label ("Z position:"),
157 zSlider
158 );
159 gridPane.add (toolbar, 0, 1);
160
161 // Start the show
162
163 stage.setTitle ("Label Test");
164 stage.setScene (new Scene (gridPane, 800, 600));
165 stage.show();
166
167 } // start
168
169 private void updateLabels () {
170
171 nodeToLabelMap.forEach ((node, label) -> {
172 var coord = node.localToScene (Point3D.ZERO, true);
173 System.out.println ("label = " + label.getText() + ", coord = " + coord);
174 label.getTransforms().setAll (new Translate(coord.getX(), coord.getY()));
175 });
176
177 } // updateLabels
178
179 public static void main (String[] args) {
180
181 launch (args);
182
183 } // main
184
185} // LabelTest class
186#!/bin/sh
187
188set -x
189
190export PATH_TO_FX=javafx-sdk-14/lib
191
192javac --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest.java
193if [ $? -ne 0 ] ; then
194 exit 1
195fi
196
197java -cp . --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest
198label = Y axis, coord = Point3D [x = 17448.00808897467, y = 21535.846392310217, z = 0.0]
199label = X axis, coord = Point3D [x = 26530.33870777918, y = 12453.515773505665, z = 0.0]
200label = Z axis, coord = Point3D [x = 17448.008088974653, y = 12453.515773505665, z = 0.0]
201- var viewScene = new SubScene (new Group (scene3d), 500, 500);
202
203- scene3d.widthProperty().bind (viewScene.widthProperty());
204- scene3d.heightProperty().bind (viewScene.heightProperty());
205- var stackPane = new StackPane (viewScene);
206- viewScene.heightProperty().bind (stackPane.heightProperty());
207- viewScene.widthProperty().bind (stackPane.widthProperty());
208- viewScene.setManaged (false);
209
210+ var stackPane = new StackPane (sceneRoot);
211+ scene3d.heightProperty().bind (stackPane.heightProperty());
212+ scene3d.widthProperty().bind (stackPane.widthProperty());
213
That works fine now for me:
1import javafx.application.Application;
2import javafx.application.Platform;
3import javafx.scene.Group;
4import javafx.scene.Node;
5import javafx.scene.PerspectiveCamera;
6import javafx.scene.SubScene;
7import javafx.scene.Scene;
8import javafx.scene.SceneAntialiasing;
9import javafx.scene.AmbientLight;
10import javafx.scene.PointLight;
11import javafx.scene.control.Label;
12import javafx.scene.control.Slider;
13import javafx.scene.control.ToolBar;
14import javafx.scene.layout.GridPane;
15import javafx.scene.layout.StackPane;
16import javafx.scene.layout.Priority;
17import javafx.scene.shape.Sphere;
18import javafx.scene.paint.Color;
19import javafx.scene.paint.PhongMaterial;
20import javafx.scene.transform.Rotate;
21import javafx.scene.transform.Translate;
22import javafx.stage.Stage;
23import javafx.geometry.Point3D;
24
25import java.util.Map;
26import java.util.HashMap;
27
28public class LabelTest extends Application {
29
30 private Map<Node, Label> nodeToLabelMap;
31
32 @Override
33 public void start (Stage stage) {
34
35 // Create main scene graph
36
37 var objects3d = new Group();
38
39 Rotate xRotate = new Rotate (0, 0, 0, 0, Rotate.X_AXIS);
40 Rotate yRotate = new Rotate (0, 0, 0, 0, Rotate.Y_AXIS);
41 objects3d.getTransforms().addAll (
42 xRotate,
43 yRotate
44 );
45
46 var root3d = new Group();
47 root3d.getChildren().add (objects3d);
48
49 var camera = new PerspectiveCamera (true);
50 camera.setTranslateZ (-25);
51
52 var scene3d = new SubScene (root3d, 500, 500, true, SceneAntialiasing.BALANCED);
53 scene3d.setFill (Color.rgb (20, 20, 80));
54 scene3d.setCamera (camera);
55
56 var sceneRoot = new Group (scene3d);
57 var objects2d = new Group();
58 sceneRoot.getChildren().add (objects2d);
59 var viewScene = new SubScene (sceneRoot, 500, 500);
60
61 scene3d.widthProperty().bind (viewScene.widthProperty());
62 scene3d.heightProperty().bind (viewScene.heightProperty());
63
64 // Add lights and objects
65
66 var ambient = new AmbientLight (Color.color (0.7, 0.7, 0.7));
67 var point = new PointLight (Color.color (0.3, 0.3, 0.3));
68 point.setTranslateX (-25);
69 point.setTranslateY (-25);
70 point.setTranslateZ (-50);
71
72 root3d.getChildren().addAll (ambient, point);
73
74 var globe = new Sphere (5);
75 globe.setMaterial (new PhongMaterial (Color.color (0.3, 0.3, 0.3)));
76
77 var xSphere = new Sphere (0.5);
78 xSphere.setMaterial (new PhongMaterial (Color.RED));
79 xSphere.setTranslateX (5);
80
81 var ySphere = new Sphere (0.5);
82 ySphere.setMaterial (new PhongMaterial (Color.GREEN));
83 ySphere.setTranslateY (5);
84
85 var zSphere = new Sphere (0.5);
86 zSphere.setMaterial (new PhongMaterial (Color.BLUE));
87 zSphere.setTranslateZ (5);
88
89 objects3d.getChildren().addAll (globe, xSphere, ySphere, zSphere);
90
91 var nubMaterial = new PhongMaterial (Color.color (0.2, 0.2, 0.2));
92 for (int i = 0; i < 200; i++) {
93 var nub = new Sphere (0.125);
94 nub.setMaterial (nubMaterial);
95 var phi = 2*Math.PI*Math.random();
96 var theta = Math.acos (2*Math.random() - 1);
97 var z = -5 * Math.sin (theta) * Math.cos (phi);
98 var x = 5 * Math.sin (theta) * Math.sin (phi);
99 var y = -5 * Math.cos (theta);
100 nub.setTranslateX (x);
101 nub.setTranslateY (y);
102 nub.setTranslateZ (z);
103 objects3d.getChildren().add (nub);
104 } // for
105
106 // Add labels
107
108 var xLabel = new Label ("X axis");
109 xLabel.setTextFill (Color.RED);
110
111 var yLabel = new Label ("Y axis");
112 yLabel.setTextFill (Color.GREEN);
113
114 var zLabel = new Label ("Z axis");
115 zLabel.setTextFill (Color.BLUE);
116
117 objects2d.getChildren().addAll (xLabel, yLabel, zLabel);
118
119 nodeToLabelMap = new HashMap<>();
120 nodeToLabelMap.put (xSphere, xLabel);
121 nodeToLabelMap.put (ySphere, yLabel);
122 nodeToLabelMap.put (zSphere, zLabel);
123
124 xRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
125 yRotate.angleProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
126 camera.translateZProperty().addListener ((obs, oldVal, newVal) -> updateLabels());
127 Platform.runLater (() -> updateLabels());
128
129 // Create main pane
130
131 var gridPane = new GridPane();
132
133 var stackPane = new StackPane (viewScene);
134 viewScene.heightProperty().bind (stackPane.heightProperty());
135 viewScene.widthProperty().bind (stackPane.widthProperty());
136 viewScene.setManaged (false);
137
138 gridPane.add (stackPane, 0, 0);
139 gridPane.setVgrow (stackPane, Priority.ALWAYS);
140 gridPane.setHgrow (stackPane, Priority.ALWAYS);
141
142 // Add controls
143
144 var xSlider = new Slider (-90, 90, 0);
145 xRotate.angleProperty().bind (xSlider.valueProperty());
146 var ySlider = new Slider (-180, 180, 0);
147 yRotate.angleProperty().bind (ySlider.valueProperty());
148 var zSlider = new Slider (-60, -25, -25);
149 camera.translateZProperty().bind (zSlider.valueProperty());
150
151 ToolBar toolbar = new ToolBar (
152 new Label ("X rotation:"),
153 xSlider,
154 new Label ("Y rotation:"),
155 ySlider,
156 new Label ("Z position:"),
157 zSlider
158 );
159 gridPane.add (toolbar, 0, 1);
160
161 // Start the show
162
163 stage.setTitle ("Label Test");
164 stage.setScene (new Scene (gridPane, 800, 600));
165 stage.show();
166
167 } // start
168
169 private void updateLabels () {
170
171 nodeToLabelMap.forEach ((node, label) -> {
172 var coord = node.localToScene (Point3D.ZERO, true);
173 System.out.println ("label = " + label.getText() + ", coord = " + coord);
174 label.getTransforms().setAll (new Translate(coord.getX(), coord.getY()));
175 });
176
177 } // updateLabels
178
179 public static void main (String[] args) {
180
181 launch (args);
182
183 } // main
184
185} // LabelTest class
186#!/bin/sh
187
188set -x
189
190export PATH_TO_FX=javafx-sdk-14/lib
191
192javac --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest.java
193if [ $? -ne 0 ] ; then
194 exit 1
195fi
196
197java -cp . --module-path $PATH_TO_FX --add-modules javafx.controls LabelTest
198label = Y axis, coord = Point3D [x = 17448.00808897467, y = 21535.846392310217, z = 0.0]
199label = X axis, coord = Point3D [x = 26530.33870777918, y = 12453.515773505665, z = 0.0]
200label = Z axis, coord = Point3D [x = 17448.008088974653, y = 12453.515773505665, z = 0.0]
201- var viewScene = new SubScene (new Group (scene3d), 500, 500);
202
203- scene3d.widthProperty().bind (viewScene.widthProperty());
204- scene3d.heightProperty().bind (viewScene.heightProperty());
205- var stackPane = new StackPane (viewScene);
206- viewScene.heightProperty().bind (stackPane.heightProperty());
207- viewScene.widthProperty().bind (stackPane.widthProperty());
208- viewScene.setManaged (false);
209
210+ var stackPane = new StackPane (sceneRoot);
211+ scene3d.heightProperty().bind (stackPane.heightProperty());
212+ scene3d.widthProperty().bind (stackPane.widthProperty());
213label = Z axis, coord = Point3D [x = 613.2085772621016, y = 286.33580935946725, z = 0.0]
214label = X axis, coord = Point3D [x = 401.67010722785966, y = 219.90328164976754, z = 0.0]
215label = Y axis, coord = Point3D [x = 400.0, y = 503.57735384935296, z = 0.0]
216
QUESTION
Basic angular app fails to run, Error module build failed : cannot find module ../@angular-devkit/src/babel/X
Asked 2022-Feb-01 at 12:16I am new to angular and was following the documentation to build a basic app.
Node - v14.7.3
npm - 7.22.0
Angular CLI: 12.2.4
OS: win32 x64
@angular-devkit/architect 0.1202.4
@angular-devkit/build-angular 12.2.4
@angular-devkit/core 12.2.4
@angular-devkit/schematics 12.2.4
@schematics/angular 12.2.4
rxjs 6.6.7
typescript 4.3.5
So far all I have done is
npm install @angular/cli
followed by ng new firstApp
and ng serve
Following is the error that I am receiving,
1√ Browser application bundle generation complete.
2
3Initial Chunk Files | Names | Size
4runtime.js | runtime | 4.89 kB
5main.js | main | 3.56 kB
6polyfills.js | polyfills | 3.55 kB
7styles.js | styles | 3.54 kB
8
9 | Initial Total | 15.54 kB
10
11Build at: 2021-09-06T06:20:42.162Z - Hash: f81b11c218148f716cf3 - Time: 10951ms
12
13../../../../#Development/Files/angularProjects/firstApp/src/main.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\babel\webpack-loader.js'
14Require stack:
15- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
16- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
17- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
18- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
19- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
20- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
21- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
22- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
23- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
24- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
25- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
26- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
27- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
28- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
29- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
30- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
31 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
32 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
33 at Module.require (internal/modules/cjs/loader.js:974:19)
34 at require (internal/modules/cjs/helpers.js:92:18)
35 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
36 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
37 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
38 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
39 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
40 at NormalModule.needBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:1192:32)
41
42../../../../#Development/Files/angularProjects/firstApp/src/polyfills.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@ngtools\webpack\src\ivy\index.js'
43Require stack:
44- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
45- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
46- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
47- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
48- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
49- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
50- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
51- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
52- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
53- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
54- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
55- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
56- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
57- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
58- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
59- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
60 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
61 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
62 at Module.require (internal/modules/cjs/loader.js:974:19)
63 at require (internal/modules/cjs/helpers.js:92:18)
64 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
65 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
66 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
67 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
68 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
69 at NormalModule.needBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:1192:32)
70
71../../../../#Development/Files/angularProjects/firstApp/src/styles.css - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\mini-css-extract-plugin\dist\loader.js'
72Require stack:
73- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
74- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
75- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
76- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
77- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
78- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
79- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
80- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
81- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
82- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
83- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
84- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
85- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
86- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
87- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
88- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
89 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
90 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
91 at Module.require (internal/modules/cjs/loader.js:974:19)
92 at require (internal/modules/cjs/helpers.js:92:18)
93 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
94 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
95 at Hook.CALL_DELEGATE [as _call] (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\Hook.js:14:14)
96 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
97 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
98 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
99
100../../../../#Development/Files/angularProjects/firstApp/src/app/app.component.css - Error: Module build failed (from ../../../../#Development/Files/angularProjects/firstApp/node_modules/postcss-loader/dist/cjs.js):
101Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\postcss-loader\dist\cjs.js'
102Require stack:
103- F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\loadLoader.js
104- F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js
105- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModuleFactory.js
106- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compiler.js
107- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
108- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
109- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
110- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
111- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
112- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
113- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
114- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
115- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
116- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
117- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
118- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
119- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
120- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
121- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
122- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
123 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
124 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
125 at Module.require (internal/modules/cjs/loader.js:974:19)
126 at require (internal/modules/cjs/helpers.js:92:18)
127 at loadLoader (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\loadLoader.js:19:17)
128 at iteratePitchingLoaders (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js:182:2)
129 at runLoaders (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js:397:2)
130 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:773:3)
131 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
132 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
133
134Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
135
136Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
137
138Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
139
140Error: node_modules/@angular/platform-browser/platform-browser.d.ts:45:22 - error NG6002: Appears in the NgModule.imports of AppModule, but could not be resolved to an NgModule class.
141
142This likely means that the library (@angular/platform-browser) which declares BrowserModule has not been processed correctly by ngcc, or is not compatible with Angular Ivy. Check if a newer version of the library is available, and update if so. Also consider checking with the library's authors to see if the library is expected to be compatible with Ivy.
143
14445 export declare class BrowserModule {
145
I have tried the following approaches to fix this issue,
Please suggest some solutions, thank you
ANSWER
Answered 2021-Sep-10 at 07:17Try to install those modules separately npm install
:
1√ Browser application bundle generation complete.
2
3Initial Chunk Files | Names | Size
4runtime.js | runtime | 4.89 kB
5main.js | main | 3.56 kB
6polyfills.js | polyfills | 3.55 kB
7styles.js | styles | 3.54 kB
8
9 | Initial Total | 15.54 kB
10
11Build at: 2021-09-06T06:20:42.162Z - Hash: f81b11c218148f716cf3 - Time: 10951ms
12
13../../../../#Development/Files/angularProjects/firstApp/src/main.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\babel\webpack-loader.js'
14Require stack:
15- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
16- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
17- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
18- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
19- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
20- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
21- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
22- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
23- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
24- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
25- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
26- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
27- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
28- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
29- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
30- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
31 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
32 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
33 at Module.require (internal/modules/cjs/loader.js:974:19)
34 at require (internal/modules/cjs/helpers.js:92:18)
35 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
36 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
37 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
38 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
39 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
40 at NormalModule.needBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:1192:32)
41
42../../../../#Development/Files/angularProjects/firstApp/src/polyfills.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@ngtools\webpack\src\ivy\index.js'
43Require stack:
44- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
45- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
46- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
47- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
48- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
49- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
50- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
51- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
52- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
53- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
54- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
55- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
56- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
57- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
58- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
59- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
60 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
61 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
62 at Module.require (internal/modules/cjs/loader.js:974:19)
63 at require (internal/modules/cjs/helpers.js:92:18)
64 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
65 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
66 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
67 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
68 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
69 at NormalModule.needBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:1192:32)
70
71../../../../#Development/Files/angularProjects/firstApp/src/styles.css - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\mini-css-extract-plugin\dist\loader.js'
72Require stack:
73- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
74- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
75- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
76- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
77- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
78- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
79- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
80- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
81- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
82- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
83- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
84- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
85- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
86- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
87- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
88- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
89 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
90 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
91 at Module.require (internal/modules/cjs/loader.js:974:19)
92 at require (internal/modules/cjs/helpers.js:92:18)
93 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
94 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
95 at Hook.CALL_DELEGATE [as _call] (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\Hook.js:14:14)
96 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
97 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
98 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
99
100../../../../#Development/Files/angularProjects/firstApp/src/app/app.component.css - Error: Module build failed (from ../../../../#Development/Files/angularProjects/firstApp/node_modules/postcss-loader/dist/cjs.js):
101Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\postcss-loader\dist\cjs.js'
102Require stack:
103- F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\loadLoader.js
104- F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js
105- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModuleFactory.js
106- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compiler.js
107- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
108- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
109- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
110- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
111- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
112- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
113- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
114- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
115- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
116- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
117- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
118- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
119- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
120- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
121- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
122- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
123 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
124 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
125 at Module.require (internal/modules/cjs/loader.js:974:19)
126 at require (internal/modules/cjs/helpers.js:92:18)
127 at loadLoader (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\loadLoader.js:19:17)
128 at iteratePitchingLoaders (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js:182:2)
129 at runLoaders (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js:397:2)
130 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:773:3)
131 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
132 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
133
134Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
135
136Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
137
138Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
139
140Error: node_modules/@angular/platform-browser/platform-browser.d.ts:45:22 - error NG6002: Appears in the NgModule.imports of AppModule, but could not be resolved to an NgModule class.
141
142This likely means that the library (@angular/platform-browser) which declares BrowserModule has not been processed correctly by ngcc, or is not compatible with Angular Ivy. Check if a newer version of the library is available, and update if so. Also consider checking with the library's authors to see if the library is expected to be compatible with Ivy.
143
14445 export declare class BrowserModule {
145npm i @angular-devkit/build-angular
146
1√ Browser application bundle generation complete.
2
3Initial Chunk Files | Names | Size
4runtime.js | runtime | 4.89 kB
5main.js | main | 3.56 kB
6polyfills.js | polyfills | 3.55 kB
7styles.js | styles | 3.54 kB
8
9 | Initial Total | 15.54 kB
10
11Build at: 2021-09-06T06:20:42.162Z - Hash: f81b11c218148f716cf3 - Time: 10951ms
12
13../../../../#Development/Files/angularProjects/firstApp/src/main.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\babel\webpack-loader.js'
14Require stack:
15- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
16- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
17- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
18- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
19- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
20- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
21- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
22- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
23- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
24- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
25- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
26- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
27- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
28- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
29- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
30- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
31 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
32 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
33 at Module.require (internal/modules/cjs/loader.js:974:19)
34 at require (internal/modules/cjs/helpers.js:92:18)
35 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
36 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
37 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
38 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
39 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
40 at NormalModule.needBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:1192:32)
41
42../../../../#Development/Files/angularProjects/firstApp/src/polyfills.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@ngtools\webpack\src\ivy\index.js'
43Require stack:
44- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
45- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
46- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
47- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
48- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
49- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
50- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
51- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
52- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
53- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
54- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
55- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
56- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
57- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
58- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
59- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
60 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
61 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
62 at Module.require (internal/modules/cjs/loader.js:974:19)
63 at require (internal/modules/cjs/helpers.js:92:18)
64 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
65 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
66 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
67 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
68 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
69 at NormalModule.needBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:1192:32)
70
71../../../../#Development/Files/angularProjects/firstApp/src/styles.css - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\mini-css-extract-plugin\dist\loader.js'
72Require stack:
73- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
74- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
75- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
76- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
77- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
78- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
79- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
80- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
81- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
82- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
83- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
84- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
85- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
86- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
87- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
88- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
89 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
90 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
91 at Module.require (internal/modules/cjs/loader.js:974:19)
92 at require (internal/modules/cjs/helpers.js:92:18)
93 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js:412:9
94 at Hook.eval [as call] (eval at create (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\HookCodeFactory.js:19:10), <anonymous>:7:1)
95 at Hook.CALL_DELEGATE [as _call] (F:\#Development\Files\angularProjects\firstApp\node_modules\tapable\lib\Hook.js:14:14)
96 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:768:24)
97 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
98 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
99
100../../../../#Development/Files/angularProjects/firstApp/src/app/app.component.css - Error: Module build failed (from ../../../../#Development/Files/angularProjects/firstApp/node_modules/postcss-loader/dist/cjs.js):
101Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\postcss-loader\dist\cjs.js'
102Require stack:
103- F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\loadLoader.js
104- F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js
105- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModuleFactory.js
106- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compiler.js
107- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
108- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
109- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
110- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
111- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
112- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
113- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
114- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
115- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js
116- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\export-ref.js
117- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\schematics\tools\index.js
118- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\utilities\json-schema.js
119- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\command-runner.js
120- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\lib\cli\index.js
121- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\lib\init.js
122- C:\Users\Admin\AppData\Roaming\npm\node_modules\@angular\cli\bin\ng
123 at Function.Module._resolveFilename (internal/modules/cjs/loader.js:902:15)
124 at Function.Module._load (internal/modules/cjs/loader.js:746:27)
125 at Module.require (internal/modules/cjs/loader.js:974:19)
126 at require (internal/modules/cjs/helpers.js:92:18)
127 at loadLoader (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\loadLoader.js:19:17)
128 at iteratePitchingLoaders (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js:182:2)
129 at runLoaders (F:\#Development\Files\angularProjects\firstApp\node_modules\loader-runner\lib\LoaderRunner.js:397:2)
130 at NormalModule.doBuild (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:773:3)
131 at NormalModule.build (F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\NormalModule.js:920:15)
132 at F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\Compilation.js:1322:12
133
134Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
135
136Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
137
138Error: Module not found: Error: Can't resolve 'F:\#Development\Files\angularProjects\firstApp\node_modules\webpack-dev-server\client\index.js?http://0.0.0.0:0&sockPath=/sockjs-node' in 'F:\#Development\Files\angularProjects\firstApp'
139
140Error: node_modules/@angular/platform-browser/platform-browser.d.ts:45:22 - error NG6002: Appears in the NgModule.imports of AppModule, but could not be resolved to an NgModule class.
141
142This likely means that the library (@angular/platform-browser) which declares BrowserModule has not been processed correctly by ngcc, or is not compatible with Angular Ivy. Check if a newer version of the library is available, and update if so. Also consider checking with the library's authors to see if the library is expected to be compatible with Ivy.
143
14445 export declare class BrowserModule {
145npm i @angular-devkit/build-angular
146npm i @ngtools/webpack
147
1√ Browser application bundle generation complete.
2
3Initial Chunk Files | Names | Size
4runtime.js | runtime | 4.89 kB
5main.js | main | 3.56 kB
6polyfills.js | polyfills | 3.55 kB
7styles.js | styles | 3.54 kB
8
9 | Initial Total | 15.54 kB
10
11Build at: 2021-09-06T06:20:42.162Z - Hash: f81b11c218148f716cf3 - Time: 10951ms
12
13../../../../#Development/Files/angularProjects/firstApp/src/main.ts - Error: Module build failed: Error: Cannot find module 'F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\babel\webpack-loader.js'
14Require stack:
15- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\ProgressPlugin.js
16- F:\#Development\Files\angularProjects\firstApp\node_modules\webpack\lib\index.js
17- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\webpack\index.js
18- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-webpack\src\index.js
19- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\build-angular\src\dev-server\index.js
20- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\node-modules-architect-host.js
21- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular-devkit\architect\node\index.js
22- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\models\architect-command.js
23- F:\#Development\Files\angularProjects\firstApp\node_modules\@angular\cli\commands\serve-impl.js