
Security News
Crates.io Users Targeted by Phishing Emails
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
phoenix-event-display
Advanced tools
A highly modular and API driven experiment independent event display that uses three.js for processing and presenting detector geometry and event data.
To use in your application, install the package.
npm install phoenix-event-display
# or
yarn add phoenix-event-display
To create a simple event display.
// Import required classes
import { EventDisplay, PhoenixLoader } from 'phoenix-event-display';
// Create the event display
const eventDisplay = new EventDisplay();
// Define the configuration
const configuration = {
elementId: '<wrapper_element_id>',
eventDataLoader: new PhoenixLoader(), // or some other event data loader
// ... other configuration options
};
// Initialize the event display with the configuration
eventDisplay.init(configuration);
// Load and parse event data in Phoenix format and display it
fetch('path/to/event-data.json')
.then((res) => res.json())
.then((res) => {
eventDisplay.parsePhoenixEvents(res);
});
// Load detector geometry
eventDisplay.loadOBJGeometry(
'path/to/geometry.obj',
'Detector OBJ',
0x8c8c8c /* color */,
);
Phoenix can be bundled and used directly in the HTML as a script along with three.js. You can either use the CDN or build from source.
To build Phoenix as a bundle.
yarn build:bundle
This will generate a file phoenix.min.js
in the ./dist/bundle directory which can be included in your HTML code.
Without building, you can include the bundle directly from CDN.
<html lang="en">
<head>
...
</head>
<body>
<div id="eventDisplay"></div>
<script src="https://cdn.jsdelivr.net/npm/three/build/three.min.js"></script>
<script src="https://cdn.jsdelivr.net/npm/phoenix-event-display/dist/bundle/phoenix.min.js"></script>
<script>
// Create the event display
const eventDisplay = new EventDisplay();
// Define the configuration
const configuration = {
elementId: 'eventDisplay',
eventDataLoader: new PhoenixLoader(), // or some other event data loader
// ... other configuration options
};
// Initialize the event display with the configuration
eventDisplay.init(configuration);
// ... other event display functions
</script>
</body>
</html>
3.0.4 (2024-11-29)
Note: Version bump only for package root
FAQs
API for web-based experiment independent event display.
The npm package phoenix-event-display receives a total of 11 weekly downloads. As such, phoenix-event-display popularity was classified as not popular.
We found that phoenix-event-display demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The Rust Security Response WG is warning of phishing emails from rustfoundation.dev targeting crates.io users.
Product
Socket now lets you customize pull request alert headers, helping security teams share clear guidance right in PRs to speed reviews and reduce back-and-forth.
Product
Socket's Rust support is moving to Beta: all users can scan Cargo projects and generate SBOMs, including Cargo.toml-only crates, with Rust-aware supply chain checks.