Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address tech debt #86

Merged
merged 4 commits into from
Sep 20, 2024
Merged

Address tech debt #86

merged 4 commits into from
Sep 20, 2024

Conversation

jordanjones243
Copy link
Contributor

@jordanjones243 jordanjones243 commented Sep 20, 2024

Alaska Airlines Pull Request

Please include a summary of the change and which issue is fixed. Please also include relevant motivation and context. List any dependencies that are required for this change.

Resolves: # (issue, if applicable)

Summary:

Please summarize the scope of the changes you have submitted, what the intent of the work is and anything that describes the before/after state of the project.

  • Point to use auro-library scripts rather than local scripts
  • Refactor custom component registration config
  • Add ability to add tag name as attribute when component is custom registered
  • Use new eslint configuration
  • Update dependencies

Type of change:

Please delete options that are not relevant.

  • New capability
  • Revision of an existing capability
  • Infrastructure change (automation, etc.)
  • Other (please elaborate)

Checklist:

  • My update follows the CONTRIBUTING guidelines of this project
  • I have performed a self-review of my own update

By submitting this Pull Request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

Pull Requests will be evaluated by their quality of update and whether it is consistent with the goals and values of this project. Any submission is to be considered a conversation between the submitter and the maintainers of this project and may require changes to your submission.

Thank you for your submission!

-- Auro Design System Team

Summary by Sourcery

Refactor component registration to utilize auro-library scripts, introduce a new feature for custom component tag attributes, update ESLint configuration, and refresh documentation to align with these changes.

New Features:

  • Introduce the ability to add a tag name as an attribute when a component is custom registered.

Enhancements:

  • Refactor the custom component registration to use auro-library scripts instead of local scripts.
  • Adopt a new ESLint configuration for improved code quality and consistency.

Build:

  • Update project dependencies to their latest versions.

Documentation:

  • Remove outdated documentation regarding CSS custom property fallbacks.
  • Update documentation to reflect changes in demo file naming conventions and component registration methods.

@jordanjones243 jordanjones243 self-assigned this Sep 20, 2024
@jordanjones243 jordanjones243 requested a review from a team as a code owner September 20, 2024 17:42
Copy link

sourcery-ai bot commented Sep 20, 2024

Reviewer's Guide by Sourcery

This pull request addresses technical debt by refactoring component registration, updating dependencies, and improving code organization. The changes focus on using the Auro Design System's library scripts, modernizing the codebase, and enhancing maintainability.

File-Level Changes

Change Details Files
Refactored component registration using Auro library scripts
  • Replaced custom registerComponent function with RuntimeUtils.default.prototype.registerComponent
  • Updated component registration in demo files
  • Added runtimeUtils import and usage in the main component file
index.js
demo/index.html
src/auro-table.js
demo/index.md
docs/partials/index.md
Updated dependencies and modernized build process
  • Updated design-tokens and webcorestylesheets versions
  • Removed CSS custom property fallbacks section from README
  • Added new eslint configuration file (eslint.config.mjs)
README.md
eslint.config.mjs
Improved code organization and documentation
  • Renamed demo.md to index.md for consistency
  • Updated file references in HTML comments
  • Removed unnecessary eslint-disable comments
demo/index.html
demo/index.md
docs/partials/index.md
demo/api.html
src/auro-table.js
Removed deprecated files and scripts
  • Deleted generateDocs.mjs script
  • Deleted staticStyles-template.js script
scripts/generateDocs.mjs
scripts/staticStyles-template.js

Tips
  • Trigger a new Sourcery review by commenting @sourcery-ai review on the pull request.
  • Continue your discussion with Sourcery by replying directly to review comments.
  • You can change your review settings at any time by accessing your dashboard:
    • Enable or disable the Sourcery-generated pull request summary or reviewer's guide;
    • Change the review language;
  • You can always contact us if you have any questions or feedback.

@jordanjones243 jordanjones243 merged commit 481b128 into beta Sep 20, 2024
3 checks passed
@jordanjones243 jordanjones243 deleted the jjones/betaTechDebt branch September 20, 2024 17:42
Copy link

@sourcery-ai sourcery-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hey @jordanjones243 - I've reviewed your changes - here's some feedback:

Overall Comments:

  • Consider keeping the CSS custom property fallbacks section in the README, as it provides valuable information for developers working with older browsers.
  • Ensure that the new eslint configuration properly handles the cases where eslint-disable comments were removed, particularly in the auro-table.js file.
Here's what I looked at during the review
  • 🟡 General issues: 2 issues found
  • 🟢 Security: all looks good
  • 🟢 Testing: all looks good
  • 🟢 Complexity: all looks good
  • 🟢 Documentation: all looks good

Sourcery is free for open source - if you like our reviews please consider sharing them ✨
Help me be more useful! Please click 👍 or 👎 on each comment to tell me if it was helpful.

@@ -34,6 +40,11 @@ export class AuroTable extends LitElement {
];
}

firstUpdated() {
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Add comment explaining the purpose of firstUpdated method

Consider adding a brief comment explaining why handling component tag rename is necessary in this lifecycle method.

  /**
   * Lifecycle method called after the component's first update.
   * Handles component tag rename for backwards compatibility.
   */
  firstUpdated() {

recommendedConfig: js.configs.recommended,
allConfig: js.configs.all
});
export default [...compat.extends("@aurodesignsystem/eslint-config")];
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

suggestion: Add comments explaining the purpose of this configuration

Consider adding some comments to explain the purpose and structure of this ESLint configuration for future maintainers.

// ESLint configuration extending Auro Design System's config
export default [
  ...compat.extends("@aurodesignsystem/eslint-config")
];

@blackfalcon
Copy link
Member

🎉 This PR is included in version 2.2.0-beta.2 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants