
Identify and meet prerequisites for Power BI custom visuals by confirming coding experience, selecting an editor such as Visual Studio Code, installing Node.js and powerbi-visuals-tools, and enabling developer mode.
Install powerbi-visuals-tools globally and verify the setup with pbiviz to begin building Power BI custom visuals. Bookmark the official visuals documentation for environment setup and next-step certificate installation.
Install the development certificate to prevent browser blocks when using the Power BI service, following Windows PowerShell import steps and placing the certificate in the trusted root authorities.
Initialize a new Power BI custom visual project with pbiviz, explore the default structure: assets, source files (visual.ts, settings.ts), style/visual.less, and config files (capabilities.json, pbiviz.json), and prepare the icon.
Run pbiviz start to compile the custom visual, enable developer mode in Power BI, and use the visual.ts boilerplate as a starting placeholder for building a slicer.
The latest version of the powerbi-visuals-tools does not necessarily use the latest version of the dependencies - including powerbi-visuals-api.
For example latest version of the powerbi-visuals-tools (at the time of recording) uses API 3.8.0 when the latest API version is 4.7.0
Starting from version 4.6.0 you must add the "privileges" to your capability.json file.
"privileges": [
{
"name": "WebAccess"
},
{
"name": "LocalStorage"
}
]
Define how data maps to your custom visual using data view mappings, focusing on categorical mapping with a maximum of one category, and update capabilities with data roles and conditions.
Extract data from visual update options in Power BI custom visuals and transform it into a data object with values, table name, and column name, using try-catch to handle data.
Build a slicer structure inside a Power BI custom visual by creating a container and list, rendering items from data, and handling updates to avoid duplication.
Style the slicer container in visual studio code to 100% width and height, center text, and add a hover underline via a span.
Learn to configure the Power BI custom visuals formatting panel by defining slicer settings and adding font, padding, margins, and alignment options in capabilities and settings.
Learn to style a Power BI custom visual by wiring formatting panel properties to variables, creating a set style function, and updating visuals in response to slicer settings.
Master filter functionality in Power BI custom visuals by implementing slicer filtering, configuring the visual host, and applying JSON filters with basic filter types.
Power BI custom visuals mastery guides you through making a slicer interact with the report, enabling filter state synchronization, styling selected items, and preparing the packaging for distribution.
Package your custom slicer visual by updating pbiviz.json metadata with description, support URL, github URL, and email, replace the assets icon with a custom design, and adjust Power BI formatting.
start by creating a new lollipop chart visual with powershell, then configure data view mappings for category, values, and target, adjust capabilities and api version, and test locally.
Prepare and transform data for Power BI visuals by extracting from update options. Define data interfaces, compute min and max, and format target values for consistent charts.
Add an SVG element to a Power BI custom visual with D3, update dependencies, and resize to the visual viewport, preparing for scales in the next lecture.
Define x and y scales with d3, map categories to the x domain and values to the y domain, and draw a target line using d3 enter update exit.
Measure target label width with Power BI visuals utilities and text measurement service; use value formatter to format the measure and measure SVG text to ensure gap matches label width.
Expose and customize formatting panel properties by editing capabilities json and test file, renaming data point and display name to lollipop settings, and adding radius, font size, and font family.
Add a target label to the visual by implementing a draw target label function, align its baseline to the middle of the target line, and update text and font attributes.
Add data points to the Power BI custom visual by drawing circles for each data item using x, y, and radius scales, and handle enter and update transitions.
Implement conditional formatting in a Power BI custom visual by defining a custom enumerate object instances function, using data view wildcard, and coloring data points based on the target value.
Add connectors to a Power BI visual by implementing a set style function, applying default color, line width, font family and size, and drawing connectors through update.
Learn to add and position category labels in Power BI custom visuals, placing labels above or below the target based on data, and refine alignment with styling.
Implement tooltips for a Power BI custom visual by configuring capabilities and using the host tooltip service to show and hide tooltips on mouse over data points.
Implement cross filtering for a Power BI custom visual using a selection ID and selection builder to filter the table when a data point is clicked, including category labels.
Master cross filtering and highlighting in Power BI custom visuals by enabling highlight support and marking data points with a boolean highlighted flag.
Package a Power BI custom visual by updating the pivotal json with description, support URL, and author info, then test the lollipop chart in Power BI desktop for distribution.
Create a new Power BI custom visual, integrate external SVG KPI marks, and configure data roles for value (average sales) and target with data view mappings.
Extract the value (the average sales) and target from the data view and implement a transform data function to produce a data object for a Power BI custom visual.
Prepare the KPI label layout for a Power BI custom visual by creating an icon container and enforcing a square SVG area from the viewport height.
Add an external svg icon to a Power BI custom visual and update its path based on whether the current value is above or below the target.
Unlock the full potential of Power BI by learning to create custom visuals that transform your data into compelling stories. This course will guide you through the process of developing three unique custom visuals that enhance the standard visuals available in Power BI.
Throughout the course, you will gain hands-on experience in building:
Custom Slicer: Create an intuitive single-choice menu with a separate filter reset option to simplify data navigation.
Lollipop Chart: Visualize performance against targets, complete with tooltips, cross-filtering, cross-highlighting, and conditional formatting for a truly interactive experience.
KPI Label: Design dynamic labels that display different icons based on whether the average value is above, on, or below the target. Learn to incorporate external SVG designs to enrich your custom visuals.
Key takeaways from this course include:
Understanding the structure of a custom visual project
Implementing tooltips, cross-filtering, and cross-highlighting
Applying conditional formatting to your visuals
Utilizing Microsoft Power BI Visuals Formatting Utils
Creating slicers with powerbi-models
Embedding externally-created SVG graphics into your custom visuals
Please note: This course assumes prior knowledge of D3.js. If you're new to D3, I recommend enrolling in our "D3.js - The Art of Data Visualization" course first.
Enroll now to unlock the power of custom visuals in Power BI and elevate your data storytelling skills to new heights.