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

A code gen for typescript #63

Merged
merged 7 commits into from
Dec 1, 2023
Merged

Conversation

emlyn-arkahna
Copy link
Contributor

@emlyn-arkahna emlyn-arkahna commented Dec 1, 2023

This would be published to libs\common\src\featureboard-features.ts if you were generating the features for FeatureBoard
And can then be used like (I think I'm not enterally sure on this one)

declare module '@featureboard/js-sdk' {
    // eslint-disable-next-line @typescript-eslint/no-empty-interface
    interface Features extends BardicBeatzFeatures {}
}

Questions

  • Should we be splitting these up by category
  • Should we allow users to set the name of the output file or should we update it based on the project name?
  • Why is the test failing it works locally and basically the same on for the nx plugin works ;(

Example output

export interface BardicBeatzFeatures {

    /**
    * Birthday Wishes
    * @description Send users a special message or offer on their birthday.
    */
    'birthday_wishes_engagement': boolean

    /**
    * Concurrent devices
    * @description Number of devices where users can simultaneously stream or sync their music.
    */
    'concurrent_devices_limit': number

    /**
    * Curated Playlists
    * @description Access to expertly curated playlists based on moods, genres, etc.
    */
    'curated_playlists_limit': boolean

    /**
    * Explicit Content Access
    * @description Control over access to songs with explicit content.
    */
    'explicit_content_access_toggle': boolean

    /**
    * Family Sharing
    * @description Allows sharing of the subscription benefits with family members.
    */
    'family_sharing_limit': boolean

    /**
    * Has concurrent device limit
    * @description Is there concurrent devices protection enabled?
    */
    'has_concurrent_device_limit_kill': boolean

    /**
    * High-Res Audio
    * @description Enhanced audio quality for a superior listening experience.
    */
    'high_res_audio_toggle': boolean

    /**
    * Integrated Social Features
    * @description Allow users to share what they're listening to, create public playlists, and more.
    */
    'integrated_social_features_toggle': boolean

    /**
    * Offline Downloads
    * @description Can the user download songs for offline listening
    */
    'offline_downloads_limit': boolean

    /**
    * Personalized Music Recommendations
    * @description Users receive song and playlist suggestions based on their listening history and preferences.
    */
    'personalized_music_recommendations_engagement': boolean

    /**
    * Platform Usage Tips
    * @description Share tips, tricks, and tutorials to help users get the most out of the platform.
    */
    'platform_usage_tips_engagement': boolean

    /**
    * Podcast Support
    * @description Introduce podcast streaming and subscriptions.
    */
    'podcast_support_toggle': boolean

    /**
    * Progress Bar Style
    * @description 
    */
    'progress_bar_style_ops_toggle': boolean

    /**
    * Promotion Tools
    * @description Set of tools for creators to use to promote their music on the platform (paid ad/playlist placements on basic users playlists)
    */
    'promotion_tools_toggle': boolean

    /**
    * Renewal Reminders
    * @description Users receive notifications or reminders as their subscription renewal date approaches.
    */
    'renewal_reminders_engagement': boolean

    /**
    * Serve Advertisements
    * @description Displays ads between songs or on the interface.
    */
    'serve_advertisements_kill': boolean

    /**
    * Skip Songs
    * @description Number of songs users can skip while listening.
    */
    'skip_songs_limit': number

    /**
    * Song Lyrics Integration
    * @description Display song lyrics in sync with the music.
    */
    'song_lyrics_integration_toggle': boolean
}

export type BardicBeatzFeature = keyof BardicBeatzFeatures

@emlyn-arkahna emlyn-arkahna marked this pull request as draft December 1, 2023 01:28
@emlyn-arkahna emlyn-arkahna marked this pull request as ready for review December 1, 2023 02:25
@emlyn-arkahna emlyn-arkahna merged commit 283b2b1 into main Dec 1, 2023
1 check passed
@emlyn-arkahna emlyn-arkahna deleted the feature/BaseTypescriptCodeGen branch December 1, 2023 07:05
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